@mojawork/ui-docs 2.6.1 → 2.8.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 (59) hide show
  1. package/README.md +2 -2
  2. package/catalog/atoms/image-grid.md +45 -1
  3. package/catalog/atoms/inline-spinner.md +188 -0
  4. package/catalog/atoms/mosaic.md +1 -1
  5. package/catalog/atoms/reader-doc.md +25 -0
  6. package/catalog/forms/chip.md +285 -0
  7. package/catalog/guide.json +69 -7
  8. package/catalog/layout/spinner.md +7 -0
  9. package/catalog/manifest.json +29 -5
  10. package/catalog/version.json +2 -2
  11. package/package.json +1 -1
  12. package/storybook/2621.2245d387.iframe.bundle.js +1 -0
  13. package/storybook/4555.525bbef9.iframe.bundle.js +1 -0
  14. package/storybook/9045.46ed3f61.iframe.bundle.js +2 -0
  15. package/storybook/{_external-mwork-music-player-docs-mdx.6f943768.iframe.bundle.js → _external-mwork-music-player-docs-mdx.3d0f7156.iframe.bundle.js} +1 -1
  16. package/storybook/_external-mwork-music-player-mwork-music-player-stories.26c06b83.iframe.bundle.js +1 -0
  17. package/storybook/atoms-_electrons-loader-docs-mdx.1176957f.iframe.bundle.js +1 -0
  18. package/storybook/atoms-_electrons-loader-loader-component-stories.8edadc42.iframe.bundle.js +1 -0
  19. package/storybook/atoms-image-grid-docs-mdx.7cb6414e.iframe.bundle.js +1 -0
  20. package/storybook/atoms-image-grid-image-grid-component-stories.8290e900.iframe.bundle.js +1 -0
  21. package/storybook/atoms-inline-spinner-docs-mdx.a98163b8.iframe.bundle.js +1 -0
  22. package/storybook/atoms-inline-spinner-inline-spinner-component-stories.76f59aa8.iframe.bundle.js +1 -0
  23. package/storybook/{atoms-mosaic-mosaic-component-stories.0a6bc043.iframe.bundle.js → atoms-mosaic-mosaic-component-stories.c2ec95f2.iframe.bundle.js} +1 -1
  24. package/storybook/atoms-reader-doc-docs-mdx.1860338f.iframe.bundle.js +1 -0
  25. package/storybook/atoms-reader-doc-reader-doc-component-stories.8ccd618b.iframe.bundle.js +1 -0
  26. package/storybook/{atoms-thumb-docs-mdx.2143ad01.iframe.bundle.js → atoms-thumb-docs-mdx.7286b617.iframe.bundle.js} +1 -1
  27. package/storybook/{atoms-thumb-thumb-component-stories.06f51d03.iframe.bundle.js → atoms-thumb-thumb-component-stories.f7e9dbae.iframe.bundle.js} +1 -1
  28. package/storybook/{atoms-typewriter-docs-mdx.3b1088c0.iframe.bundle.js → atoms-typewriter-docs-mdx.993bc264.iframe.bundle.js} +1 -1
  29. package/storybook/atoms-typewriter-typewriter-component-stories.80f07c89.iframe.bundle.js +1 -0
  30. package/storybook/examples-image-grid-slider-docs-mdx.d3578699.iframe.bundle.js +1 -0
  31. package/storybook/examples-image-grid-slider-image-grid-slider-stories.cda91b79.iframe.bundle.js +1 -0
  32. package/storybook/forms-chip-chip-component-stories.90a45ea4.iframe.bundle.js +1 -0
  33. package/storybook/forms-chip-docs-mdx.01e1b518.iframe.bundle.js +1 -0
  34. package/storybook/{home-overview-mdx.0d4ede52.iframe.bundle.js → home-overview-mdx.a2833e60.iframe.bundle.js} +1 -1
  35. package/storybook/iframe.html +3 -3
  36. package/storybook/index.json +1 -1
  37. package/storybook/layout-spinner-docs-mdx.03741741.iframe.bundle.js +1 -0
  38. package/storybook/layout-spinner-spinner-component-stories.69ae1389.iframe.bundle.js +1 -0
  39. package/storybook/{main.e33bfc7e33aad318b1d2.css → main.4530991c57c404682bbb.css} +16 -0
  40. package/storybook/main.5e4e255f.iframe.bundle.js +1 -0
  41. package/storybook/project.json +1 -1
  42. package/storybook/runtime~main.a2ec52c2.iframe.bundle.js +1 -0
  43. package/storybook/version.json +2 -2
  44. package/version.json +2 -2
  45. package/storybook/4555.251b232c.iframe.bundle.js +0 -1
  46. package/storybook/9045.a50616e9.iframe.bundle.js +0 -2
  47. package/storybook/_external-mwork-music-player-mwork-music-player-stories.08fbf651.iframe.bundle.js +0 -1
  48. package/storybook/atoms-image-grid-docs-mdx.18b4df2a.iframe.bundle.js +0 -1
  49. package/storybook/atoms-image-grid-image-grid-component-stories.a0a92d9e.iframe.bundle.js +0 -1
  50. package/storybook/atoms-reader-doc-docs-mdx.0688c3b9.iframe.bundle.js +0 -1
  51. package/storybook/atoms-reader-doc-reader-doc-component-stories.a6fec57d.iframe.bundle.js +0 -1
  52. package/storybook/atoms-typewriter-typewriter-component-stories.4fefc019.iframe.bundle.js +0 -1
  53. package/storybook/examples-image-grid-slider-docs-mdx.9e38157e.iframe.bundle.js +0 -1
  54. package/storybook/examples-image-grid-slider-image-grid-slider-stories.028c8c2b.iframe.bundle.js +0 -1
  55. package/storybook/layout-spinner-docs-mdx.4be572c0.iframe.bundle.js +0 -1
  56. package/storybook/layout-spinner-spinner-component-stories.ab8245c6.iframe.bundle.js +0 -1
  57. package/storybook/main.1f12809e.iframe.bundle.js +0 -1
  58. package/storybook/runtime~main.52ba2f02.iframe.bundle.js +0 -1
  59. /package/storybook/{9045.a50616e9.iframe.bundle.js.LICENSE.txt → 9045.46ed3f61.iframe.bundle.js.LICENSE.txt} +0 -0
@@ -1,8 +1,8 @@
1
1
  {
2
2
  "author": "an agent — the Claude Code session of the library workspace, writing from the sources each entry names; not a person",
3
3
  "disclaimer": "Recommendations, not truth. Every entry was written by an agent from the sources it names, and only for what demonstrably runs somewhere in the house (shownIn). The component page — get_component_doc — is the truth; where the two disagree, the page wins. The house rules are read verbatim from the usage contract of the library (usage.md).",
4
- "uiVersion": "2.6.1",
5
- "commit": "830ad1b4",
4
+ "uiVersion": "2.8.0",
5
+ "commit": "a8fd26f2",
6
6
  "entries": [
7
7
  {
8
8
  "kind": "situation",
@@ -452,6 +452,33 @@
452
452
  ],
453
453
  "reviewed": "69197b72"
454
454
  },
455
+ {
456
+ "kind": "component",
457
+ "component": "ui-chip",
458
+ "useFor": [
459
+ "A small label that reports presses — a set filter above a table, a genre on a record, a tag that can be thrown away.",
460
+ "Rows of them: the parent holds the list, the chip only says the cross was pressed."
461
+ ],
462
+ "notFor": [
463
+ "Removing itself: chipRemove is a message, and the list belongs to whoever holds it.",
464
+ "A selection: it has no active state and no group — a set of chips behaving as one choice is a different component.",
465
+ "A form control: it takes no value, no ngModel and no validation."
466
+ ],
467
+ "shownIn": [
468
+ {
469
+ "story": "Forms/Chip/ARow",
470
+ "url": "https://moja.work/storybook/?path=/story/forms-chip--a-row"
471
+ },
472
+ {
473
+ "story": "Forms/Chip/Removable",
474
+ "url": "https://moja.work/storybook/?path=/story/forms-chip--removable"
475
+ }
476
+ ],
477
+ "sources": [
478
+ "libs/ui/src/lib/forms/chip/docs.mdx"
479
+ ],
480
+ "reviewed": "8e6e0c56"
481
+ },
455
482
  {
456
483
  "kind": "component",
457
484
  "component": "ui-clock",
@@ -533,7 +560,8 @@
533
560
  "kind": "component",
534
561
  "component": "ui-image-grid",
535
562
  "useFor": [
536
- "The overview of a picture set, sharing one index with ui-image-slider. Always set cols; the default draws nothing."
563
+ "The overview of a picture set, sharing one index with ui-image-slider. Always set cols; the default draws nothing.",
564
+ "A strip — one scrolling row of fixed-size tiles (singleRow with tileHeight and tileAspect): episode stills, a row of posters."
537
565
  ],
538
566
  "notFor": [
539
567
  "Showing one picture large — that is the slider's half."
@@ -542,6 +570,10 @@
542
570
  "ui-image-slider"
543
571
  ],
544
572
  "shownIn": [
573
+ {
574
+ "story": "Atoms/Image Grid/Strip",
575
+ "url": "https://moja.work/storybook/?path=/story/atoms-image-grid--strip"
576
+ },
545
577
  {
546
578
  "story": "Examples/Image Gallery/ImageGallery",
547
579
  "url": "https://moja.work/storybook/?path=/story/examples-image-gallery--image-gallery"
@@ -558,7 +590,7 @@
558
590
  "libs/ui/src/lib/atoms/image-grid/docs.mdx",
559
591
  "libs/ui/.storybook/demos/examples/image-grid-slider/docs.mdx"
560
592
  ],
561
- "reviewed": "69197b72"
593
+ "reviewed": "a5e154c7"
562
594
  },
563
595
  {
564
596
  "kind": "component",
@@ -591,6 +623,32 @@
591
623
  ],
592
624
  "reviewed": "592c82aa"
593
625
  },
626
+ {
627
+ "kind": "component",
628
+ "component": "ui-inline-spinner",
629
+ "useFor": [
630
+ "The loading state of ONE area — a panel waiting for its record, a tile waiting for a picture. It sits in the flow, blocks nothing and covers nothing."
631
+ ],
632
+ "notFor": [
633
+ "The application's global wait: that is ui-layout-spinner, placed once at the root and switched through its service.",
634
+ "Holding the loading state: it shows while it is in the DOM, so an @if around the tag is the switch.",
635
+ "Progress: all three visuals are indeterminate, none of them can show how far along something is."
636
+ ],
637
+ "shownIn": [
638
+ {
639
+ "story": "Atoms/Inline Spinner/Types",
640
+ "url": "https://moja.work/storybook/?path=/story/atoms-inline-spinner--types"
641
+ },
642
+ {
643
+ "story": "Atoms/Inline Spinner/InAPanel",
644
+ "url": "https://moja.work/storybook/?path=/story/atoms-inline-spinner--in-a-panel"
645
+ }
646
+ ],
647
+ "sources": [
648
+ "libs/ui/src/lib/atoms/inline-spinner/docs.mdx"
649
+ ],
650
+ "reviewed": "8e6e0c56"
651
+ },
594
652
  {
595
653
  "kind": "component",
596
654
  "component": "ui-input",
@@ -810,7 +868,7 @@
810
868
  "The one global loading indicator at the app root, driven by UiLayoutSpinnerService from an HTTP interceptor."
811
869
  ],
812
870
  "notFor": [
813
- "A component's own loading state — the table wrapper has its skeleton, everything else is local styling."
871
+ "A component's own loading state — that is ui-inline-spinner, which sits in the flow and blocks nothing; the table wrapper brings its own skeleton."
814
872
  ],
815
873
  "shownIn": [
816
874
  {
@@ -824,7 +882,7 @@
824
882
  "sources": [
825
883
  "libs/ui/src/lib/layout/spinner/docs.mdx"
826
884
  ],
827
- "reviewed": "592c82aa"
885
+ "reviewed": "8e6e0c56"
828
886
  },
829
887
  {
830
888
  "kind": "component",
@@ -1012,6 +1070,10 @@
1012
1070
  "story": "Atoms/ReaderDoc/DroppedMarkup",
1013
1071
  "url": "https://moja.work/storybook/?path=/story/atoms-readerdoc--dropped-markup"
1014
1072
  },
1073
+ {
1074
+ "story": "Atoms/ReaderDoc/Emphasis",
1075
+ "url": "https://moja.work/storybook/?path=/story/atoms-readerdoc--emphasis"
1076
+ },
1015
1077
  {
1016
1078
  "file": "apps/website/src/app/content/content.component.html"
1017
1079
  }
@@ -1019,7 +1081,7 @@
1019
1081
  "sources": [
1020
1082
  "libs/ui/src/lib/atoms/reader-doc/docs.mdx"
1021
1083
  ],
1022
- "reviewed": "69197b72"
1084
+ "reviewed": "2ae02124"
1023
1085
  },
1024
1086
  {
1025
1087
  "kind": "component",
@@ -12,6 +12,13 @@ It shows, animates out and hides; it does not count requests, time out or block
12
12
  input on its own, and it is not the spinner for one component's own loading
13
13
  state.
14
14
 
15
+ That last sentence now has an address: `ui-inline-spinner` is the one for a
16
+ single area. Both draw the same animation — it lives in an internal electron
17
+ that each of them builds in, so the library holds one set of keyframes rather
18
+ than two that drift. What stays here is what makes this one global: the
19
+ backdrop, the message box with its OK button, and the state coming from the
20
+ service.
21
+
15
22
  ---
16
23
 
17
24
  > **Guide:** recommendations for `ui-layout-spinner` — use for, not for, instead, shown in — are served by `get_guide` (name: `ui-layout-spinner`). The section above is the truth; the guide is the offer.
@@ -1,7 +1,7 @@
1
1
  {
2
- "uiVersion": "2.6.1",
3
- "commit": "830ad1b4",
4
- "builtAt": "2026-08-25T22:07:34.554Z",
2
+ "uiVersion": "2.8.0",
3
+ "commit": "a8fd26f2",
4
+ "builtAt": "2026-08-30T00:25:45.207Z",
5
5
  "guide": "guide.json",
6
6
  "usage": "usage.md",
7
7
  "mcp": "mcp.json",
@@ -114,6 +114,18 @@
114
114
  "truth": "A styled wrapper around a projected native checkbox (`ui-tag`): the label, an\noptional self-painted icon variant, and the validation display through\n`uiError`. Semantics, keyboard handling and form integration are the native\ninput's; the component adds the look and the error reporting. It is the control\nfor a choice that can be required or invalid — a toggle that is always valid\nis `ui-switch`.\n\n---",
115
115
  "api": "https://moja.work/compodoc/ui/components/UiCheckboxComponent.html"
116
116
  },
117
+ {
118
+ "component": "chip",
119
+ "selector": "ui-chip",
120
+ "aliases": [],
121
+ "className": "UiChipComponent",
122
+ "area": "forms",
123
+ "file": "forms/chip.md",
124
+ "description": "A small label that reports what is done to it.",
125
+ "brief": "It shows the text it is given and emits — a set filter, a chosen genre, a tag on a record.",
126
+ "truth": "It shows the text it is given and emits — a set filter, a chosen genre, a tag\non a record. What a press MEANS is the consumer's answer: the chip does not\nselect itself, does not mark itself active, and above all **does not remove\nitself**. It says the cross was pressed; taking it out of the list is the job\nof whoever holds the list.\n\nThat is the whole component. It has no active state, no group, no selection\nmodel and no keyboard walk across a row — a set of chips that behave as one\nchoice is a different thing, and it is not this one.\n\n---",
127
+ "api": "https://moja.work/compodoc/ui/components/UiChipComponent.html"
128
+ },
117
129
  {
118
130
  "component": "switch",
119
131
  "selector": "ui-switch",
@@ -291,7 +303,7 @@
291
303
  "file": "atoms/image-grid.md",
292
304
  "description": "The `UiImageGridComponent` is a versatile and responsive grid-based image display component. It allows for dynamic configuration of columns, gaps, and heights, making it suitable for galleries, portfolios, or any grouped image presentation.",
293
305
  "brief": "Lays pictures out in a fixed number of columns, with a gap, a height and an optional overlay per tile, and reports which tile is selected or clicked.",
294
- "truth": "Lays pictures out in a fixed number of columns, with a gap, a height and an\noptional overlay per tile, and reports which tile is selected or clicked. It\nshares an index with `ui-image-slider` (`setIndex`/`currentIndex`) so grid and\nslider can point at the same picture. It opens nothing itself: a click emits\n`clickIndex`, and what follows — a slider in zoom, a route — is the host's\ndecision. `cols` must be set; the default `0` draws no columns.\n\n---",
306
+ "truth": "Lays pictures out in a fixed number of columns, with a gap, a height and an\noptional overlay per tile, and reports which tile is selected or clicked. It\nshares an index with `ui-image-slider` (`setIndex`/`currentIndex`) so grid and\nslider can point at the same picture. It opens nothing itself: a click emits\n`clickIndex`, and what follows — a slider in zoom, a route — is the host's\ndecision. `cols` must be set; the default `0` draws no columns.\n\nAs a **strip** (`singleRow` with a `tileHeight`) it is one row of equally\nsized tiles that scrolls sideways once there are more than fit — a row of\nepisode stills, a row of posters. Then `cols` plays no part, nothing is\npadded, and `tileAspect` gives the tile its shape. `imageFit` decides how\na tile holds its picture in either mode: at its own size (the default), or\nfilling the tile, or fitted whole.\n\n---",
295
307
  "api": "https://moja.work/compodoc/ui/components/UiImageGridComponent.html"
296
308
  },
297
309
  {
@@ -378,6 +390,18 @@
378
390
  "truth": "Switches between projected `<section>` blocks, one per name in `tabNames`,\nwith real buttons in a `tablist` the keyboard reaches. Labels are generated\nwhen none are given; the active tab can be set and is reported. It keeps the\nsections in the DOM and switches what is visible; it does not route, lazy-load\nor remember the active tab across a reload.\n\n---",
379
391
  "api": "https://moja.work/compodoc/ui/components/UiLayoutTabsComponent.html"
380
392
  },
393
+ {
394
+ "component": "inline-spinner",
395
+ "selector": "ui-inline-spinner",
396
+ "aliases": [],
397
+ "className": "UiInlineSpinnerComponent",
398
+ "area": "atoms",
399
+ "file": "atoms/inline-spinner.md",
400
+ "description": "A loading indicator for one area of a page.",
401
+ "brief": "It turns, where it is put.",
402
+ "truth": "It turns, where it is put. That is the whole component: no backdrop, no focus\ntrap, no service, no message, nothing blocked. A panel waiting for its record,\na tile waiting for a picture, a list waiting for a page — the indicator sits in\nthe flow and the layout around it stays where it is.\n\nIt is the counterpart to `ui-layout-spinner`, which is the application's single\nglobal overlay and says of itself that it is not the spinner for one\ncomponent's own loading state. This one is that spinner.\n\n**It shows whenever it is in the DOM.** Whether something is loading is the\nconsumer's question, and an `@if` around the tag is the honest answer to it —\na `loading` input would only move the same boolean one level down and add a\nstate the component would have to be trusted with.\n\nBoth draw the same animation: it lives in an internal electron that the global\nspinner builds in as well, so there is one set of keyframes in the library and\nnot two that drift.\n\n---",
403
+ "api": "https://moja.work/compodoc/ui/components/UiInlineSpinnerComponent.html"
404
+ },
381
405
  {
382
406
  "component": "spinner",
383
407
  "selector": "ui-layout-spinner",
@@ -387,7 +411,7 @@
387
411
  "file": "layout/spinner.md",
388
412
  "description": "A global loading indicator that provides visual feedback during asynchronous operations.",
389
413
  "brief": "A global loading indicator, placed once at the application root and switched through `UiLayoutSpinnerService` from anywhere — an HTTP interceptor, typically.",
390
- "truth": "A global loading indicator, placed once at the application root and switched\nthrough `UiLayoutSpinnerService` from anywhere — an HTTP interceptor, typically.\nIt shows, animates out and hides; it does not count requests, time out or block\ninput on its own, and it is not the spinner for one component's own loading\nstate.\n\n---",
414
+ "truth": "A global loading indicator, placed once at the application root and switched\nthrough `UiLayoutSpinnerService` from anywhere — an HTTP interceptor, typically.\nIt shows, animates out and hides; it does not count requests, time out or block\ninput on its own, and it is not the spinner for one component's own loading\nstate.\n\nThat last sentence now has an address: `ui-inline-spinner` is the one for a\nsingle area. Both draw the same animation — it lives in an internal electron\nthat each of them builds in, so the library holds one set of keyframes rather\nthan two that drift. What stays here is what makes this one global: the\nbackdrop, the message box with its OK button, and the state coming from the\nservice.\n\n---",
391
415
  "api": "https://moja.work/compodoc/ui/components/UiLayoutSpinnerComponent.html"
392
416
  },
393
417
  {
@@ -1,4 +1,4 @@
1
1
  {
2
- "commit": "830ad1b4",
3
- "uiVersion": "2.6.1"
2
+ "commit": "a8fd26f2",
3
+ "uiVersion": "2.8.0"
4
4
  }
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@mojawork/ui-docs",
3
- "version": "2.6.1",
3
+ "version": "2.8.0",
4
4
  "description": "The documentation of @mojawork/ui, version-true: the built Storybook plus the cooked catalog (truth pages, guide, usage contract, tool definitions). npx-startable.",
5
5
  "license": "MIT",
6
6
  "type": "module",
@@ -0,0 +1 @@
1
+ (self.webpackChunkmoja_work=self.webpackChunkmoja_work||[]).push([[2621],{"./libs/ui/src/lib/atoms/image-grid/image-grid-click-area.directive.ts"(__unused_webpack_module,__webpack_exports__,__webpack_require__){"use strict";__webpack_require__.d(__webpack_exports__,{u:()=>UiImageGridClickAreaDirective});var tslib__WEBPACK_IMPORTED_MODULE_0__=__webpack_require__("./node_modules/tslib/tslib.es6.mjs"),_angular_core__WEBPACK_IMPORTED_MODULE_1__=__webpack_require__("./node_modules/@angular/core/fesm2022/_debug_node-chunk.mjs"),_angular_core__WEBPACK_IMPORTED_MODULE_2__=__webpack_require__("./node_modules/@angular/core/fesm2022/_effect-chunk2.mjs");let UiImageGridClickAreaDirective=class UiImageGridClickAreaDirective{template=(0,_angular_core__WEBPACK_IMPORTED_MODULE_2__.WQX)(_angular_core__WEBPACK_IMPORTED_MODULE_1__.C4Q);static ngTemplateContextGuard(_directive,_context){return!0}};UiImageGridClickAreaDirective=(0,tslib__WEBPACK_IMPORTED_MODULE_0__.Cg)([(0,_angular_core__WEBPACK_IMPORTED_MODULE_1__.WLR)({selector:"ng-template[uiImageGridClickArea]"})],UiImageGridClickAreaDirective)},"./libs/ui/src/lib/atoms/image-grid/image-grid.component.ts"(__unused_webpack_module,__webpack_exports__,__webpack_require__){"use strict";__webpack_require__.d(__webpack_exports__,{p:()=>UiImageGridComponent});var tslib_es6=__webpack_require__("./node_modules/tslib/tslib.es6.mjs");var image_grid_componentngResource=__webpack_require__("./libs/ui/src/lib/atoms/image-grid/image-grid.component.css?ngResource"),image_grid_componentngResource_default=__webpack_require__.n(image_grid_componentngResource),_common_module_chunk=__webpack_require__("./node_modules/@angular/common/fesm2022/_common_module-chunk.mjs"),core=__webpack_require__("./node_modules/@angular/core/fesm2022/core.mjs"),_debug_node_chunk=__webpack_require__("./node_modules/@angular/core/fesm2022/_debug_node-chunk.mjs"),_resource_chunk=__webpack_require__("./node_modules/@angular/core/fesm2022/_resource-chunk.mjs"),_effect_chunk2=__webpack_require__("./node_modules/@angular/core/fesm2022/_effect-chunk2.mjs"),resize_signal=__webpack_require__("./libs/ui/src/lib/helpers/resize-signal.ts"),image_grid_click_area_directive=__webpack_require__("./libs/ui/src/lib/atoms/image-grid/image-grid-click-area.directive.ts");let UiImageGridComponent=class UiImageGridComponent{get scrollerHeightValue(){return this.scrollerHeight()}get fitClass(){return`_-fit-${this.imageFit()}`}scroller;imageContainer;clickArea=(0,core.contentChild)(image_grid_click_area_directive.u,{read:_debug_node_chunk.C4Q});resizeEvent=(0,resize_signal.H)();data=(0,core.input)(null);dataCount=(0,_resource_chunk.EW)(()=>this.data()?.length??0);dataCountItems=(0,_effect_chunk2.vPA)([0]);debug=(0,core.input)(!1);singleRow=(0,core.input)(!1);gap=(0,core.input)(0);overlayType=(0,core.input)("default");overlayTypeClass=(0,_resource_chunk.EW)(()=>`_-${this.overlayType()}`);cols=(0,core.input)(0);height=(0,core.input)();tileHeight=(0,core.input)();tileAspect=(0,core.input)("1/1");imageFit=(0,core.input)("none");action=(0,core.input)(!1);loaded=(0,core.input)(!1);setIndex=(0,core.input)(0);currentIndex=(0,core.output)();clickIndex=(0,core.output)();strip=(0,_resource_chunk.EW)(()=>this.singleRow()&&Boolean(this.tileHeight()));tileWidth=(0,_resource_chunk.EW)(()=>{const height=this.tileHeight()??0,[w,h]=this.tileAspect().split("/").map(Number),ratio=w>0&&h>0?w/h:1;return Math.round(height*ratio)});scrollerHeight=(0,_resource_chunk.EW)(()=>{const height=this.height(),cols=this.cols();return this.strip()?`${this.tileHeight()}px`:this.singleRow()&&height&&cols?height/cols+"px":height?`${height}px`:"200px"});gridColsInternal=(0,_resource_chunk.EW)(()=>{const counter=this.cols();return this.singleRow()?counter:0!==counter&&this.dataCount()/counter>counter?Math.ceil(this.dataCount()/counter):counter});active=(0,_effect_chunk2.vPA)(null);broken=(0,_effect_chunk2.vPA)(new Set);hideDisplay=(0,_effect_chunk2.vPA)(!0);clickAreaExist=(0,_resource_chunk.EW)(()=>void 0!==this.clickArea());constructor(){(0,_effect_chunk2.QZP)(()=>{this.gap(),this.height(),this.cols(),this.tileHeight(),this.tileAspect(),this.resizeEvent(),this.updateGrid()}),(0,_effect_chunk2.QZP)(()=>{this.data(),this.broken.set(new Set)}),(0,_effect_chunk2.QZP)(()=>{this.setIndex(),this.scrollToChild(this.setIndex()),this.active.set(this.setIndex())}),(0,_effect_chunk2.QZP)(()=>{this.action(),this.active.set(null)})}ngAfterViewInit(){this.active.set(this.setIndex()),this.updateGrid(),this.fader()}clickAreaContext(index){const item=this.data()?.[index];return item?{$implicit:item,index}:null}updateGrid(){const scroller=this.scroller?.nativeElement;scroller&&(scroller.style.height=this.scrollerHeight());const element=this.imageContainer?.nativeElement;if(element&&this.dataCount()){const gap=this.gap(),tiles=this.singleRow()?this.dataCount():this.gridColsInternal()*this.gridColsInternal();this.dataCountItems.set(Array.from({length:tiles},(_,index)=>index+1));const repeatCount=this.singleRow()?this.dataCount():this.gridColsInternal(),track=this.strip()?`${this.tileWidth()}px`:"1fr";setTimeout(()=>{element.style.display="grid",element.style.gap=`${gap}px`,element.style.gridTemplateColumns=`repeat(${repeatCount}, ${track})`,element.style.width=this.strip()?"max-content":"",this.applyStylesToChildren()},100)}}calculateGridSize(containerSize){const adjustedSize=containerSize/this.cols()-this.gap();return Math.ceil(adjustedSize)}applyStylesToChildren(){const element=this.imageContainer?.nativeElement;if(element){const strip=this.strip(),width=strip?this.tileWidth():this.calculateGridSize(element.offsetWidth??0),height=strip?this.tileHeight()??0:this.singleRow()?element.offsetHeight:this.calculateGridSize(element.offsetHeight??0),applyChildStyles=child=>{child.style.height=`${height}px`,child.style.width=`${width}px`};element.childNodes.forEach(child=>{child instanceof HTMLElement&&applyChildStyles(child)})}}fader(){this.hideDisplay.set(!0),setTimeout(()=>{this.hideDisplay.set(!1)},800)}scrollToChild(index){const containerElement=this.imageContainer?.nativeElement;if(!containerElement)return;const targetChild=containerElement.childNodes[index];if(!(targetChild instanceof HTMLElement))return;const scrollOffset=this.calculateScrollOffset(containerElement,targetChild);this.scroller?.nativeElement.scrollTo({left:scrollOffset,top:0})}calculateScrollOffset(container,child){return child.offsetLeft-container.offsetWidth/2+child.offsetWidth/2}useAction(index){this.action()&&this.imageSrc(index)&&(this.clickAreaExist()&&this.active()===index&&this.clickIndex.emit(index),this.currentIndex.emit(index),this.active.set(index),this.scrollToChild(index))}scale(index){const value=this.data()?.[index]?.src.scale;return`transform: scale(${value??1})`}markBroken(index){this.broken.update(current=>new Set(current).add(index))}imageSrc(index){return this.data()?.[index]?.src.default}imageAlt(index){return this.data()?.[index]?.alt}imageTitle(index){return this.data()?.[index]?.title}static ctorParameters=()=>[];static propDecorators={scrollerHeightValue:[{type:_debug_node_chunk.g$6,args:["style.height"]}],fitClass:[{type:_debug_node_chunk.g$6,args:["class"]}],scroller:[{type:core.ViewChild,args:["scroller"]}],imageContainer:[{type:core.ViewChild,args:["imageContainer"]}],clickArea:[{type:core.ContentChild,args:[image_grid_click_area_directive.u,{read:_debug_node_chunk.C4Q,isSignal:!0}]}],data:[{type:_debug_node_chunk.pde,args:[{isSignal:!0,alias:"data",required:!1,transform:void 0}]}],debug:[{type:_debug_node_chunk.pde,args:[{isSignal:!0,alias:"debug",required:!1,transform:void 0}]}],singleRow:[{type:_debug_node_chunk.pde,args:[{isSignal:!0,alias:"singleRow",required:!1,transform:void 0}]}],gap:[{type:_debug_node_chunk.pde,args:[{isSignal:!0,alias:"gap",required:!1,transform:void 0}]}],overlayType:[{type:_debug_node_chunk.pde,args:[{isSignal:!0,alias:"overlayType",required:!1,transform:void 0}]}],cols:[{type:_debug_node_chunk.pde,args:[{isSignal:!0,alias:"cols",required:!1,transform:void 0}]}],height:[{type:_debug_node_chunk.pde,args:[{isSignal:!0,alias:"height",required:!1,transform:void 0}]}],tileHeight:[{type:_debug_node_chunk.pde,args:[{isSignal:!0,alias:"tileHeight",required:!1,transform:void 0}]}],tileAspect:[{type:_debug_node_chunk.pde,args:[{isSignal:!0,alias:"tileAspect",required:!1,transform:void 0}]}],imageFit:[{type:_debug_node_chunk.pde,args:[{isSignal:!0,alias:"imageFit",required:!1,transform:void 0}]}],action:[{type:_debug_node_chunk.pde,args:[{isSignal:!0,alias:"action",required:!1,transform:void 0}]}],loaded:[{type:_debug_node_chunk.pde,args:[{isSignal:!0,alias:"loaded",required:!1,transform:void 0}]}],setIndex:[{type:_debug_node_chunk.pde,args:[{isSignal:!0,alias:"setIndex",required:!1,transform:void 0}]}],currentIndex:[{type:_debug_node_chunk.k7i,args:["currentIndex"]}],clickIndex:[{type:_debug_node_chunk.k7i,args:["clickIndex"]}]}};UiImageGridComponent=(0,tslib_es6.Cg)([(0,_debug_node_chunk.uAl)({selector:"ui-image-grid",template:'@if (data()) {\n <div class="_scroller" #scroller>\n <div\n #imageContainer\n class="_image-container"\n [class._-hide-display]="hideDisplay()"\n >\n @for (item of dataCountItems(); track item; let i = $index) {\n <button\n class="_wrapper"\n [class._-action]="action() && imageSrc(i)"\n [class._-active]="active() === i"\n [class._-no-image]="!imageSrc(i)"\n [class]="overlayTypeClass()"\n (click)="useAction(i)"\n >\n @if (debug()) {\n dataCount: {{ this.dataCount() }} <br />\n internalCounter: {{ this.gridColsInternal() }} <br />\n counter: {{ this.cols() }} <br />\n src: {{ imageSrc(i) }}\n } @else {\n @if (imageSrc(i) && loaded()) {\n @if (broken().has(i)) {\n \x3c!-- The file did not load: the alt text stands in the tile,\n centred, the same in every fit mode — a sized broken\n <img> would draw the browser\'s icon in a corner. --\x3e\n <figure class="_-broken"><figcaption>{{ imageAlt(i) }}</figcaption></figure>\n } @else {\n <figure>\n <img\n [style]="scale(i)"\n [src]="imageSrc(i)"\n [alt]="imageAlt(i)"\n [title]="imageTitle(i)"\n (error)="markBroken(i)"\n />\n </figure>\n }\n @if (clickArea(); as template) {\n <div class="_click-area">\n <ng-container\n *ngTemplateOutlet="template; context: clickAreaContext(i)"\n ></ng-container>\n </div>\n }\n } @else {\n \x3c!-- No picture: the same shape the image editor uses — icon\n centred, whatever title the item carries underneath. No\n stand-in text: an empty title is the caller\'s business. --\x3e\n <div class="_empty">\n <span class="ui-icon x3" aria-hidden="true">image</span>\n <strong>{{ imageTitle(i) }}</strong>\n </div>\n }\n }\n </button>\n }\n </div>\n </div>\n}\n',imports:[_common_module_chunk.T3],styles:[image_grid_componentngResource_default()]}),(0,tslib_es6.Sn)("design:paramtypes",[])],UiImageGridComponent)},"./libs/ui/src/lib/atoms/image-grid/image-grid.component.css?ngResource"(module,__unused_webpack_exports,__webpack_require__){var ___CSS_LOADER_API_NO_SOURCEMAP_IMPORT___=__webpack_require__("./node_modules/css-loader/dist/runtime/noSourceMaps.js"),___CSS_LOADER_EXPORT___=__webpack_require__("./node_modules/css-loader/dist/runtime/api.js")(___CSS_LOADER_API_NO_SOURCEMAP_IMPORT___);___CSS_LOADER_EXPORT___.push([module.id,"@layer ui.base, ui.components;\n@layer ui.components {\n:host {\n /* The scroller and the grid inside are positioned absolutely; the host is\n their anchor. Without this they climbed to the nearest positioned\n ancestor — an overlay's top edge, in one consumer. */\n position: relative;\n z-index: 0;\n --wrapper-height: 60rem;\n --button-size: 4rem;\n display: flex;\n /* Fills its container by default; the named hooks let a consumer set a fixed\n size without a cascade fight (tickets#241, tickets#251). */\n width: var(--ui-image-grid-width, 100%);\n height: var(--ui-image-grid-height, 100%);\n border-radius: calc(var(--ui-border-width) * 4);\n\n ._scroller {\n position: absolute;\n top: 0;\n left: 0;\n display: flex;\n width: 100%;\n height: 100%;\n overflow-y: hidden;\n overflow-x: scroll;\n background-color: var(--ui-c-background);\n scroll-behavior: smooth;\n }\n\n ._image-container {\n position: absolute;\n top: 0;\n left: 0;\n display: grid;\n width: 100%;\n height: 100%;\n transition: opacity calc(var(--ui-time) * 0.1) linear;\n\n &._-hide-display {\n opacity: 0;\n }\n\n button._wrapper {\n position: relative;\n display: flex;\n width: 100%;\n height: 100%;\n gap: calc(var(--ui-spacer) * 0.5);\n align-items: center;\n justify-content: center;\n overflow: hidden;\n transition: scale calc(var(--ui-time) * 0.5) ease-in-out;\n background-color: var(--ui-c-fourthly);\n border: 0;\n\n &._-no-image {\n cursor: default;\n opacity: 0.5;\n }\n\n /* A picture that did not load: its alt text, centred in the tile —\n the same look whatever the fit mode. */\n figure._-broken {\n width: 100%;\n height: 100%;\n justify-content: center;\n\n figcaption {\n padding: calc(var(--ui-spacer) * 0.25);\n text-align: center;\n }\n }\n\n /* The empty state, same arrangement as the image editor's: icon above,\n title below, both dimmed. */\n ._empty {\n display: flex;\n flex-direction: column;\n align-items: center;\n justify-content: center;\n gap: calc(var(--ui-spacer) * 0.25);\n }\n\n &._-default {\n &:not(._-action) {\n cursor: default;\n }\n\n &._-active {\n border: 0.32rem solid var(--ui-c-focus);\n\n img {\n transform: scale(1.1) !important;\n }\n }\n\n &._-action:hover {\n img {\n transform: scale(1.1) !important;\n }\n }\n }\n\n &._-doors {\n &._-active {\n border: 0.32rem solid var(--ui-c-focus);\n }\n\n &._-action:hover {\n img {\n transform: scale(1.1) !important;\n }\n }\n\n &::after,\n &::before {\n z-index: 1;\n content: '\\00a0';\n position: absolute;\n left: 0;\n display: flex;\n height: 100%;\n width: 100%;\n background-color: var(--ui-c-background);\n transition: var(--ui-time) ease-in-out;\n opacity: 0.6;\n }\n\n &::before {\n top: -50%;\n z-index: 1;\n }\n\n &::after {\n top: 50%;\n }\n\n &._-active::before {\n opacity: 0;\n top: -100%;\n }\n\n &._-active::after {\n opacity: 0;\n top: 100%;\n }\n }\n\n figure {\n position: relative;\n display: flex;\n flex-flow: column;\n justify-content: center;\n align-items: center;\n padding: 0;\n\n img {\n width: auto;\n max-width: initial;\n aspect-ratio: auto;\n transition: transform calc(var(--ui-time) * 0.5) ease-in-out;\n -webkit-user-select: none;\n user-select: none;\n }\n }\n\n\n ._click-area {\n position: absolute;\n display: flex;\n justify-content: center;\n align-items: center;\n width: 100%;\n height: 100%;\n opacity: 0;\n transition: var(--ui-time) ease-in-out;\n }\n\n &._-active {\n ._click-area {\n opacity: 1;\n }\n }\n }\n }\n}\n\n/* `imageFit`: the picture takes the tile and either fills it (cover) or\n fits inside it whole (contain). `none` keeps the picture at its own size,\n as above. Top level, because a nested `&` after `:host()` would name the\n host twice. */\n:host(._-fit-cover) ._image-container button._wrapper figure,\n:host(._-fit-cover) ._image-container button._wrapper figure img,\n:host(._-fit-contain) ._image-container button._wrapper figure,\n:host(._-fit-contain) ._image-container button._wrapper figure img {\n width: 100%;\n height: 100%;\n}\n\n:host(._-fit-cover) ._image-container button._wrapper figure img {\n object-fit: cover;\n}\n\n:host(._-fit-contain) ._image-container button._wrapper figure img {\n object-fit: contain;\n}\n}\n",""]),module.exports=___CSS_LOADER_EXPORT___.toString()}}]);
@@ -0,0 +1 @@
1
+ (self.webpackChunkmoja_work=self.webpackChunkmoja_work||[]).push([[4555],{"./libs/ui/guide sync \\.json$"(module,__unused_webpack_exports,__webpack_require__){var map={"./app-shell.json":"./libs/ui/guide/app-shell.json","./burger-menu.json":"./libs/ui/guide/burger-menu.json","./form-basics.json":"./libs/ui/guide/form-basics.json","./image-gallery.json":"./libs/ui/guide/image-gallery.json","./table-edit-focus.json":"./libs/ui/guide/table-edit-focus.json","./translations.json":"./libs/ui/guide/translations.json","./ui-autocomplete.json":"./libs/ui/guide/ui-autocomplete.json","./ui-background.json":"./libs/ui/guide/ui-background.json","./ui-barcode.json":"./libs/ui/guide/ui-barcode.json","./ui-buzzer.json":"./libs/ui/guide/ui-buzzer.json","./ui-card.json":"./libs/ui/guide/ui-card.json","./ui-cdk-drag-drop-splitter.json":"./libs/ui/guide/ui-cdk-drag-drop-splitter.json","./ui-cdk-table-wrapper.json":"./libs/ui/guide/ui-cdk-table-wrapper.json","./ui-chart.json":"./libs/ui/guide/ui-chart.json","./ui-checkbox.json":"./libs/ui/guide/ui-checkbox.json","./ui-chip.json":"./libs/ui/guide/ui-chip.json","./ui-clock.json":"./libs/ui/guide/ui-clock.json","./ui-copy-value.json":"./libs/ui/guide/ui-copy-value.json","./ui-image-editor.json":"./libs/ui/guide/ui-image-editor.json","./ui-image-grid.json":"./libs/ui/guide/ui-image-grid.json","./ui-image-slider.json":"./libs/ui/guide/ui-image-slider.json","./ui-inline-spinner.json":"./libs/ui/guide/ui-inline-spinner.json","./ui-input.json":"./libs/ui/guide/ui-input.json","./ui-lang-selector.json":"./libs/ui/guide/ui-lang-selector.json","./ui-layout-main.json":"./libs/ui/guide/ui-layout-main.json","./ui-layout-media-screen.json":"./libs/ui/guide/ui-layout-media-screen.json","./ui-layout-nav.json":"./libs/ui/guide/ui-layout-nav.json","./ui-layout-overlay-header.json":"./libs/ui/guide/ui-layout-overlay-header.json","./ui-layout-overlay.json":"./libs/ui/guide/ui-layout-overlay.json","./ui-layout-spinner.json":"./libs/ui/guide/ui-layout-spinner.json","./ui-layout-splitter.json":"./libs/ui/guide/ui-layout-splitter.json","./ui-layout-tabs.json":"./libs/ui/guide/ui-layout-tabs.json","./ui-layout-top-scroll-bottom.json":"./libs/ui/guide/ui-layout-top-scroll-bottom.json","./ui-mosaic.json":"./libs/ui/guide/ui-mosaic.json","./ui-placeholder.json":"./libs/ui/guide/ui-placeholder.json","./ui-qr-code.json":"./libs/ui/guide/ui-qr-code.json","./ui-rating.json":"./libs/ui/guide/ui-rating.json","./ui-reader-doc.json":"./libs/ui/guide/ui-reader-doc.json","./ui-slider.json":"./libs/ui/guide/ui-slider.json","./ui-switch.json":"./libs/ui/guide/ui-switch.json","./ui-text-animate.json":"./libs/ui/guide/ui-text-animate.json","./ui-thumb.json":"./libs/ui/guide/ui-thumb.json","./ui-timer.json":"./libs/ui/guide/ui-timer.json","./ui-typewriter.json":"./libs/ui/guide/ui-typewriter.json","libs/ui/guide/app-shell.json":"./libs/ui/guide/app-shell.json","libs/ui/guide/burger-menu.json":"./libs/ui/guide/burger-menu.json","libs/ui/guide/form-basics.json":"./libs/ui/guide/form-basics.json","libs/ui/guide/image-gallery.json":"./libs/ui/guide/image-gallery.json","libs/ui/guide/table-edit-focus.json":"./libs/ui/guide/table-edit-focus.json","libs/ui/guide/translations.json":"./libs/ui/guide/translations.json","libs/ui/guide/ui-autocomplete.json":"./libs/ui/guide/ui-autocomplete.json","libs/ui/guide/ui-background.json":"./libs/ui/guide/ui-background.json","libs/ui/guide/ui-barcode.json":"./libs/ui/guide/ui-barcode.json","libs/ui/guide/ui-buzzer.json":"./libs/ui/guide/ui-buzzer.json","libs/ui/guide/ui-card.json":"./libs/ui/guide/ui-card.json","libs/ui/guide/ui-cdk-drag-drop-splitter.json":"./libs/ui/guide/ui-cdk-drag-drop-splitter.json","libs/ui/guide/ui-cdk-table-wrapper.json":"./libs/ui/guide/ui-cdk-table-wrapper.json","libs/ui/guide/ui-chart.json":"./libs/ui/guide/ui-chart.json","libs/ui/guide/ui-checkbox.json":"./libs/ui/guide/ui-checkbox.json","libs/ui/guide/ui-chip.json":"./libs/ui/guide/ui-chip.json","libs/ui/guide/ui-clock.json":"./libs/ui/guide/ui-clock.json","libs/ui/guide/ui-copy-value.json":"./libs/ui/guide/ui-copy-value.json","libs/ui/guide/ui-image-editor.json":"./libs/ui/guide/ui-image-editor.json","libs/ui/guide/ui-image-grid.json":"./libs/ui/guide/ui-image-grid.json","libs/ui/guide/ui-image-slider.json":"./libs/ui/guide/ui-image-slider.json","libs/ui/guide/ui-inline-spinner.json":"./libs/ui/guide/ui-inline-spinner.json","libs/ui/guide/ui-input.json":"./libs/ui/guide/ui-input.json","libs/ui/guide/ui-lang-selector.json":"./libs/ui/guide/ui-lang-selector.json","libs/ui/guide/ui-layout-main.json":"./libs/ui/guide/ui-layout-main.json","libs/ui/guide/ui-layout-media-screen.json":"./libs/ui/guide/ui-layout-media-screen.json","libs/ui/guide/ui-layout-nav.json":"./libs/ui/guide/ui-layout-nav.json","libs/ui/guide/ui-layout-overlay-header.json":"./libs/ui/guide/ui-layout-overlay-header.json","libs/ui/guide/ui-layout-overlay.json":"./libs/ui/guide/ui-layout-overlay.json","libs/ui/guide/ui-layout-spinner.json":"./libs/ui/guide/ui-layout-spinner.json","libs/ui/guide/ui-layout-splitter.json":"./libs/ui/guide/ui-layout-splitter.json","libs/ui/guide/ui-layout-tabs.json":"./libs/ui/guide/ui-layout-tabs.json","libs/ui/guide/ui-layout-top-scroll-bottom.json":"./libs/ui/guide/ui-layout-top-scroll-bottom.json","libs/ui/guide/ui-mosaic.json":"./libs/ui/guide/ui-mosaic.json","libs/ui/guide/ui-placeholder.json":"./libs/ui/guide/ui-placeholder.json","libs/ui/guide/ui-qr-code.json":"./libs/ui/guide/ui-qr-code.json","libs/ui/guide/ui-rating.json":"./libs/ui/guide/ui-rating.json","libs/ui/guide/ui-reader-doc.json":"./libs/ui/guide/ui-reader-doc.json","libs/ui/guide/ui-slider.json":"./libs/ui/guide/ui-slider.json","libs/ui/guide/ui-switch.json":"./libs/ui/guide/ui-switch.json","libs/ui/guide/ui-text-animate.json":"./libs/ui/guide/ui-text-animate.json","libs/ui/guide/ui-thumb.json":"./libs/ui/guide/ui-thumb.json","libs/ui/guide/ui-timer.json":"./libs/ui/guide/ui-timer.json","libs/ui/guide/ui-typewriter.json":"./libs/ui/guide/ui-typewriter.json"};function webpackContext(req){var id=webpackContextResolve(req);return __webpack_require__(id)}function webpackContextResolve(req){if(!__webpack_require__.o(map,req)){var e=new Error("Cannot find module '"+req+"'");throw e.code="MODULE_NOT_FOUND",e}return map[req]}webpackContext.keys=function webpackContextKeys(){return Object.keys(map)},webpackContext.resolve=webpackContextResolve,module.exports=webpackContext,webpackContext.id="./libs/ui/guide sync \\.json$"},"./libs/ui/.storybook/blocks/guide.entries.js"(__unused_webpack_module,__webpack_exports__,__webpack_require__){"use strict";__webpack_require__.d(__webpack_exports__,{H:()=>guideEntries});const context=__webpack_require__("./libs/ui/guide sync \\.json$"),guideEntries=context.keys().filter(key=>key.startsWith("./")).map(key=>{const entry=context(key);return entry.default??entry});if(0===guideEntries.length)throw new Error("guide: libs/ui/guide/ holds no entries — an empty guide is a generator bug, not an empty page.");const subjects=guideEntries.map(entry=>entry.component??entry.situation),twice=subjects.find((subject,index)=>subjects.indexOf(subject)!==index);if(twice)throw new Error(`guide: "${twice}" is listed twice — one entry per subject, or the overview lies about the count.`)},"./libs/ui/.storybook/blocks/guide.model.mjs"(__unused_webpack_module,__webpack_exports__,__webpack_require__){"use strict";__webpack_require__.d(__webpack_exports__,{Cc:()=>guideModel,ED:()=>reviewedStamps,K9:()=>indexRows});var storybook_internal_csf__WEBPACK_IMPORTED_MODULE_0__=__webpack_require__("./node_modules/storybook/dist/csf/index.js");function storyHref(story){const cut=story.lastIndexOf("/");if(cut<=0||cut===story.length-1)throw new Error(`guide: story reference "${story}" is not "Title/Export".`);const title=story.slice(0,cut),name=story.slice(cut+1);return`?path=/story/${(0,storybook_internal_csf__WEBPACK_IMPORTED_MODULE_0__.Lr)(title,(0,storybook_internal_csf__WEBPACK_IMPORTED_MODULE_0__.bE)(name))}`}const subjectOf=entry=>entry.component??entry.situation;function pageOf(entries,subject){const entry=entries.find(e=>subjectOf(e)===subject),story=entry?.shownIn.find(r=>r.story)?.story;return story?(title=story.slice(0,story.lastIndexOf("/")),`?path=/docs/${(0,storybook_internal_csf__WEBPACK_IMPORTED_MODULE_0__.aj)(title)}--docs`):null;var title}function guideModel(entry,entries,of){if(!entry||"object"!=typeof entry)throw new Error(`guide: no entry handed to the block for "${of}".`);const subject=subjectOf(entry);if(void 0!==of&&subject!==of)throw new Error(`guide: the block on "${of}" was handed the entry of "${subject}" — wrong import.`);for(const key of["useFor","notFor","shownIn","sources"])if(!Array.isArray(entry[key]))throw new Error(`guide: entry "${subject}" has no "${key}" list.`);if(0===entry.shownIn.length)throw new Error(`guide: entry "${subject}" shows nothing — no proof, no block.`);return{subject,kind:entry.component?"component":"situation",uses:(entry.uses??[]).map(s=>({selector:s,href:pageOf(entries,s)})),useFor:entry.useFor,notFor:entry.notFor,instead:(entry.instead??[]).map(s=>({selector:s,href:pageOf(entries,s)})),note:entry.note??null,shownIn:entry.shownIn.map(r=>r.story?{label:r.story,href:storyHref(r.story)}:{label:r.file,href:null}),sources:entry.sources,reviewed:entry.reviewed}}function indexRows(entries){if(!Array.isArray(entries)||0===entries.length)throw new Error("guide: the overview has no entries — an empty guide is a generator bug, not an empty page.");return entries.map(e=>({subject:subjectOf(e),kind:e.component?"component":"situation",brief:e.useFor[0],href:pageOf(entries,subjectOf(e))})).sort((a,b)=>a.kind===b.kind?a.subject.localeCompare(b.subject):"situation"===a.kind?1:-1)}const reviewedStamps=entries=>[...new Set(entries.map(e=>e.reviewed))]},"./libs/ui/guide/app-shell.json"(module){"use strict";module.exports=JSON.parse('{"situation":"app-shell","uses":["ui-layout-main","ui-layout-nav","ui-layout-splitter","ui-layout-tabs"],"useFor":["The four layout components nested by content projection: main holds the nav in its header and the page in its content; a splitter inside the content holds tabs in its left pane. Each slot is a named attribute on your own element."],"notFor":["Overlays — they stand next to the layout, not inside it."],"shownIn":[{"story":"Examples/Layout/Layout"},{"file":"libs/ui/.storybook/demos/examples/layout/docs.mdx"},{"file":"apps/website/src/app/app.component.html"}],"sources":["libs/ui/.storybook/demos/examples/layout/docs.mdx"],"reviewed":"592c82aa"}')},"./libs/ui/guide/burger-menu.json"(module){"use strict";module.exports=JSON.parse('{"situation":"burger-menu","uses":["ui-layout-overlay","ui-layout-overlay-header"],"useFor":["A navigation drawer behind a burger button: the overlay with direction=\\"right\\", the header with its close, a plain link list in the overlay-content slot; every link click resets the open flag. Backdrop, Escape and the scroll-lock come with the overlay."],"notFor":["The main navigation on a wide screen — that is ui-layout-nav in the main header."],"shownIn":[{"story":"Examples/Burger Menu/BurgerMenu"},{"file":"libs/ui/src/lib/examples/docs.mdx"},{"file":"apps/website/src/app/app.component.html"}],"sources":["libs/ui/src/lib/examples/docs.mdx","libs/ui/src/lib/layout/overlay/docs.mdx"],"reviewed":"592c82aa"}')},"./libs/ui/guide/form-basics.json"(module){"use strict";module.exports=JSON.parse('{"situation":"form-basics","uses":["ui-input","ui-checkbox","ui-switch","ui-slider"],"useFor":["Every form in the house: <ui-input [label]=\\"…\\"><input ui-tag class=\\"ui\\" [(ngModel)]=\\"…\\" /></ui-input>. The wrapper brings label and error display, the native control keeps value, validation and type. class=\\"ui\\" on the control; class=\\"ui-flat\\" where it sits inline in a table cell."],"notFor":["A control without the class — it renders unstyled.","A validator written in the app: validators belong in the library."],"shownIn":[{"story":"Styling/Forms/Forms"},{"story":"Forms/Validators/Email"},{"file":"apps/change-me/src/app/slider/slider.component.html"}],"sources":["usage.md (Forms)","libs/ui/src/lib/forms/input/docs.mdx","libs/ui/src/lib/forms/validators/docs.mdx"],"reviewed":"69197b72"}')},"./libs/ui/guide/image-gallery.json"(module){"use strict";module.exports=JSON.parse('{"situation":"image-gallery","uses":["ui-image-grid","ui-image-slider"],"useFor":["Grid and slider sharing one index: side by side, or the slider created with @if as the zoom — two clicks by design of the grid, the first selects, the second (on the projected uiImageGridClickArea) emits clickIndex."],"notFor":["A single linked preview — ui-thumb."],"shownIn":[{"story":"Examples/Image Gallery/ImageGallery"},{"story":"Examples/Image Gallery/ImageGalleryZoom"},{"file":"libs/ui/.storybook/demos/examples/image-grid-slider/docs.mdx"},{"file":"apps/website/src/app/content/image-grid/image-grid.component.html"}],"sources":["libs/ui/.storybook/demos/examples/image-grid-slider/docs.mdx"],"reviewed":"69197b72"}')},"./libs/ui/guide/table-edit-focus.json"(module){"use strict";module.exports=JSON.parse('{"situation":"table-edit-focus","uses":["ui-cdk-table-wrapper","ui-input","ui-checkbox"],"useFor":["An inline-editing table walked by keyboard: the wrapper in inline fixed mode with the uiTableEditFocus directive; fields as ui-flat controls; the app answers uiRowNavigate and uiRowStep — the only two questions the library does not answer itself: may this row open, and what does locked mean — and calls focusCell() after it re-rendered the edit row."],"notFor":["A wrapper without inline mode: the cells shift when a text turns into a field.","Counting positions instead of naming buttons — the edit row carries more buttons than a read row."],"shownIn":[{"story":"Examples/Table Edit Focus/TableEditFocus"},{"story":"Examples/Table Edit Focus/TableEditFocusTall"},{"file":"libs/ui/.storybook/demos/examples/table-edit-focus/docs.mdx"},{"file":"apps/proto/src/app/examples/keyboard-table/keyboard-table.component.html"},{"file":"apps/proto/src/app/examples/keyboard-table/keyboard-table.component.ts"}],"sources":["libs/ui/.storybook/demos/examples/table-edit-focus/docs.mdx","libs/ui/src/lib/cdk/components/table/docs.mdx","media CLAUDE.md (own repo): Keyboard navigation — who owns what","tickets#168","tickets#169"],"reviewed":"69197b72"}')},"./libs/ui/guide/translations.json"(module){"use strict";module.exports=JSON.parse('{"situation":"translations","uses":["ui-lang-selector"],"useFor":["Loading the library\'s translation files alongside the app\'s own with Transloco; the selector switches both. The list of every key the library ships is generated from the loaded translation, never written beside it."],"notFor":["Translating inside a computed — it snapshots an empty dictionary on first render; use the pipe, or a translate helper that listens."],"shownIn":[{"story":"Examples/Transloco/LangSelector"},{"story":"Examples/Transloco/AllKeys"},{"file":"libs/ui/.storybook/demos/examples/transloco/docs.mdx"}],"sources":["libs/ui/.storybook/demos/examples/transloco/docs.mdx","media CLAUDE.md (own repo): translate() inside a computed is a snapshot","tickets#182"],"reviewed":"69197b72"}')},"./libs/ui/guide/ui-autocomplete.json"(module){"use strict";module.exports=JSON.parse('{"component":"ui-autocomplete","useFor":["An input whose suggestions the host supplies — an in-memory list, signals or a backend; minChars and delay keep the requests civil, the component never fetches."],"notFor":["Multi-select, chips, a dropdown of fixed options — a native select inside ui-input does the last.","A waiting state or an empty message: there is none by design."],"instead":["ui-input"],"shownIn":[{"story":"Forms/Autocomplete/Autocomplete"},{"story":"Forms/Autocomplete/Loading"}],"sources":["libs/ui/src/lib/forms/autocomplete/docs.mdx"],"reviewed":"69197b72"}')},"./libs/ui/guide/ui-background.json"(module){"use strict";module.exports=JSON.parse('{"component":"ui-background","useFor":["A patterned surface behind projected content — change-me\'s slider page puts its form on one."],"notFor":["Layout; a plain colour, which is one CSS line."],"shownIn":[{"story":"Atoms/Background/BackgroundExample"},{"file":"apps/change-me/src/app/slider/slider.component.html"}],"sources":["libs/ui/src/lib/atoms/background/docs.mdx"],"reviewed":"69197b72"}')},"./libs/ui/guide/ui-barcode.json"(module){"use strict";module.exports=JSON.parse('{"component":"ui-barcode","useFor":["Drawing an EAN-13 the app already holds — an ISBN, an internal id under its own prefix. Size comes from the outside; a utility class on the tag wins."],"notFor":["Deciding which number to draw, printing it, or reacting to a click — that stays with the app.","Any symbology but EAN-13."],"note":"Wrap it in ui-copy-value to copy the digits; the bars stay the picture.","shownIn":[{"story":"Atoms/Barcode/Default"},{"story":"Atoms/Barcode/Sizes"}],"sources":["libs/ui/src/lib/atoms/barcode/docs.mdx","media frontend (own repo): internal-barcode.spec.ts, tickets#205"],"reviewed":"69197b72"}')},"./libs/ui/guide/ui-buzzer.json"(module){"use strict";module.exports=JSON.parse('{"component":"ui-buzzer","useFor":["One big, deliberate action — a contact trigger, a push button. The website uses it twice."],"notFor":["Ordinary form buttons: those are button.ui and button.ui-flat."],"shownIn":[{"story":"Atoms/Buzzer/Buzzer"},{"file":"apps/website/src/app/content/contact/contact.component.html"},{"file":"apps/website/src/app/components/push-button/push-button.component.html"}],"sources":["libs/ui/src/lib/atoms/buzzer/docs.mdx"],"reviewed":"69197b72"}')},"./libs/ui/guide/ui-card.json"(module){"use strict";module.exports=JSON.parse('{"component":"ui-card","useFor":["A bounded surface with an optional headline and icon around projected content — a tile, a panel, a summary."],"notFor":["Anything that has to act: copying, linking, expanding. The card is presentational and composes nothing."],"instead":["ui-copy-value"],"note":"For a copyable card, wrap it: <ui-copy-value [value]=\\"…\\"><ui-card …></ui-card></ui-copy-value>. One job per component; composition, not a mode, adds the second.","shownIn":[{"story":"Atoms/Card/Card"}],"sources":["libs/ui/src/lib/atoms/card/docs.mdx","tickets#183"],"reviewed":"69197b72"}')},"./libs/ui/guide/ui-cdk-drag-drop-splitter.json"(module){"use strict";module.exports=JSON.parse('{"component":"ui-cdk-drag-drop-splitter","useFor":["Sorting items into two buckets by drag and drop. Bind both outputs and hand the new arrays back, or nothing moves."],"notFor":["A two-pane layout.","A list that persists itself."],"instead":["ui-layout-splitter"],"shownIn":[{"story":"CDK/Drag And Drop Splitter/DragAndDropSplitter"}],"sources":["libs/ui/src/lib/cdk/components/drag-and-drop-splitter/docs.mdx"],"reviewed":"69197b72"}')},"./libs/ui/guide/ui-cdk-table-wrapper.json"(module){"use strict";module.exports=JSON.parse('{"component":"ui-cdk-table-wrapper","useFor":["Any cdk-table in the house: loading skeleton, hover and focus, header colours, fixed or content layout.","Inline editing: inline fixed plus the uiTableEditFocus directive — the proto keyboard table and the media editor are built this way."],"notFor":["A table without the CDK.","Inline editing without inline mode: the cells shift when text turns into a field."],"shownIn":[{"story":"CDK/Table/Default"},{"story":"CDK/Table/Inline"},{"story":"Examples/Table Edit Focus/TableEditFocus"},{"file":"apps/proto/src/app/examples/keyboard-table/keyboard-table.component.html"}],"sources":["libs/ui/src/lib/cdk/components/table/docs.mdx","libs/ui/.storybook/demos/examples/table-edit-focus/docs.mdx","media CLAUDE.md (own repo): Keyboard navigation — who owns what"],"reviewed":"69197b72"}')},"./libs/ui/guide/ui-chart.json"(module){"use strict";module.exports=JSON.parse('{"component":"ui-chart","useFor":["A single ring or bar of up to three segments — a share, a progress. The number of colours is the number of rings."],"notFor":["Series, axes, legends, tooltips, more than three parts."],"shownIn":[{"story":"Atoms/Chart/Rings"}],"sources":["libs/ui/src/lib/atoms/chart/docs.mdx"],"reviewed":"69197b72"}')},"./libs/ui/guide/ui-checkbox.json"(module){"use strict";module.exports=JSON.parse('{"component":"ui-checkbox","useFor":["A choice that may be required or validated, inside a form that reports errors.","Flag cells of an editable table row: icons while the row is closed, checkboxes while it is edited — the proto keyboard table does that with display=\\"check-icon\\"."],"notFor":["An always-valid toggle.","The native variant where Safari matters — the self-painted icon variant renders the same everywhere."],"instead":["ui-switch"],"shownIn":[{"story":"Forms/Checkbox/CheckboxIcon"},{"story":"Forms/Checkbox/CheckboxValidation"},{"file":"apps/proto/src/app/examples/keyboard-table/keyboard-table.component.html"}],"sources":["libs/ui/src/lib/forms/checkbox/docs.mdx"],"reviewed":"69197b72"}')},"./libs/ui/guide/ui-chip.json"(module){"use strict";module.exports=JSON.parse('{"component":"ui-chip","useFor":["A small label that reports presses — a set filter above a table, a genre on a record, a tag that can be thrown away.","Rows of them: the parent holds the list, the chip only says the cross was pressed."],"notFor":["Removing itself: chipRemove is a message, and the list belongs to whoever holds it.","A selection: it has no active state and no group — a set of chips behaving as one choice is a different component.","A form control: it takes no value, no ngModel and no validation."],"shownIn":[{"story":"Forms/Chip/ARow"},{"story":"Forms/Chip/Removable"}],"sources":["libs/ui/src/lib/forms/chip/docs.mdx"],"reviewed":"8e6e0c56"}')},"./libs/ui/guide/ui-clock.json"(module){"use strict";module.exports=JSON.parse('{"component":"ui-clock","useFor":["A decorative time display — the website\'s landscape overlay."],"notFor":["A countdown; anything that needs time zones or formats beyond 12/24 h."],"instead":["ui-timer"],"shownIn":[{"story":"Atoms/Clock/Default"},{"file":"apps/website/src/app/parts/landscape-overlay/landscape-overlay.component.html"}],"sources":["libs/ui/src/lib/atoms/clock/docs.mdx"],"reviewed":"69197b72"}')},"./libs/ui/guide/ui-copy-value.json"(module){"use strict";module.exports=JSON.parse('{"component":"ui-copy-value","useFor":["Click-to-copy around anything that shows a value — a swatch, a barcode, a truncated label. What is shown and what is copied are two different things, and this carries the second."],"notFor":["Showing the value: it brings no appearance. Wrap the thing that does."],"note":"With an empty value it leaves the tab order and stops being a control, so it can stand around content unconditionally and be switched on by supplying a value.","shownIn":[{"story":"Atoms/Copy Value/Swatches"},{"story":"Atoms/Copy Value/OwnConfirmation"}],"sources":["libs/ui/src/lib/atoms/copy-value/docs.mdx","tickets#183"],"reviewed":"69197b72"}')},"./libs/ui/guide/ui-image-editor.json"(module){"use strict";module.exports=JSON.parse('{"component":"ui-image-editor","useFor":["Uploading and cropping one image to a ratio, result as a JPEG blob — a cover, an avatar. The media cover editor is the overlay variant; the embedded one sits in the flow."],"notFor":["Several images, drawing, filters.","Talking to a backend: it emits, the host uploads."],"shownIn":[{"story":"Molecules/Image Editor/WithImage"},{"story":"Molecules/Image Editor/Overlay"}],"sources":["libs/ui/src/lib/molecules/image-editor/docs.mdx"],"reviewed":"4cc1b639"}')},"./libs/ui/guide/ui-image-grid.json"(module){"use strict";module.exports=JSON.parse('{"component":"ui-image-grid","useFor":["The overview of a picture set, sharing one index with ui-image-slider. Always set cols; the default draws nothing.","A strip — one scrolling row of fixed-size tiles (singleRow with tileHeight and tileAspect): episode stills, a row of posters."],"notFor":["Showing one picture large — that is the slider\'s half."],"instead":["ui-image-slider"],"shownIn":[{"story":"Atoms/Image Grid/Strip"},{"story":"Examples/Image Gallery/ImageGallery"},{"story":"Examples/Image Gallery/ImageGalleryZoom"},{"file":"apps/website/src/app/content/image-grid/image-grid.component.html"}],"sources":["libs/ui/src/lib/atoms/image-grid/docs.mdx","libs/ui/.storybook/demos/examples/image-grid-slider/docs.mdx"],"reviewed":"a5e154c7"}')},"./libs/ui/guide/ui-image-slider.json"(module){"use strict";module.exports=JSON.parse('{"component":"ui-image-slider","useFor":["One picture at a time with swipe, drag and zoom; as the zoom of a grid, created with @if only while open."],"notFor":["The overview of a set."],"instead":["ui-image-grid"],"shownIn":[{"story":"Examples/Image Gallery/ImageGallery"},{"story":"Examples/Image Gallery/ImageGalleryZoom"},{"file":"apps/website/src/app/app.component.html"}],"sources":["libs/ui/src/lib/atoms/image-slider/docs.mdx","libs/ui/.storybook/demos/examples/image-grid-slider/docs.mdx"],"reviewed":"592c82aa"}')},"./libs/ui/guide/ui-inline-spinner.json"(module){"use strict";module.exports=JSON.parse('{"component":"ui-inline-spinner","useFor":["The loading state of ONE area — a panel waiting for its record, a tile waiting for a picture. It sits in the flow, blocks nothing and covers nothing."],"notFor":["The application\'s global wait: that is ui-layout-spinner, placed once at the root and switched through its service.","Holding the loading state: it shows while it is in the DOM, so an @if around the tag is the switch.","Progress: all three visuals are indeterminate, none of them can show how far along something is."],"shownIn":[{"story":"Atoms/Inline Spinner/Types"},{"story":"Atoms/Inline Spinner/InAPanel"}],"sources":["libs/ui/src/lib/atoms/inline-spinner/docs.mdx"],"reviewed":"8e6e0c56"}')},"./libs/ui/guide/ui-input.json"(module){"use strict";module.exports=JSON.parse('{"component":"ui-input","useFor":["Every text-based control in a form: wrap the native input, textarea or select, keep [(ngModel)] on the projected element, class=\\"ui\\" on it.","Inline editing in tables: the projected control takes class=\\"ui-flat\\" instead — invisible at rest, no layout jump. The proto keyboard table has sixteen of them."],"notFor":["Ranges, checkboxes, switches — they have wrappers of their own.","Suggestions while typing."],"instead":["ui-slider","ui-checkbox","ui-switch","ui-autocomplete"],"shownIn":[{"story":"Forms/Input/Input"},{"story":"Forms/Input/InputClearable"},{"file":"apps/change-me/src/app/slider/slider.component.html"},{"file":"apps/proto/src/app/examples/keyboard-table/keyboard-table.component.html"}],"sources":["libs/ui/src/lib/forms/input/docs.mdx","usage.md (Forms)"],"reviewed":"69197b72"}')},"./libs/ui/guide/ui-lang-selector.json"(module){"use strict";module.exports=JSON.parse('{"component":"ui-lang-selector","useFor":["The one language switch of an app: one tag brings the service call, the storage and the restore on reload."],"notFor":["More than the two languages it knows; a switch that must not persist."],"shownIn":[{"story":"Examples/Transloco/LangSelector"},{"story":"Atoms/Lang Selector/OwnContent"},{"file":"apps/website/src/app/components/lang-selector/lang-selector.component.html"}],"sources":["libs/ui/src/lib/atoms/lang-selector/docs.mdx"],"reviewed":"69197b72"}')},"./libs/ui/guide/ui-layout-main.json"(module){"use strict";module.exports=JSON.parse('{"component":"ui-layout-main","useFor":["The root of an app shell, once: the nav in its header slot, the page in its content, a footer. The website and change-me both start here."],"notFor":["A panel inside a page — splitter, tabs and top-scroll-bottom are for that."],"shownIn":[{"story":"Examples/Layout/Layout"},{"file":"apps/website/src/app/app.component.html"},{"file":"apps/change-me/src/app/app.component.html"}],"sources":["libs/ui/src/lib/layout/main/docs.mdx","libs/ui/.storybook/demos/examples/layout/docs.mdx"],"reviewed":"592c82aa"}')},"./libs/ui/guide/ui-layout-media-screen.json"(module){"use strict";module.exports=JSON.parse('{"component":"ui-layout-media-screen","useFor":["Once in the app shell, so every breakpoint question goes to UiLayoutMediaScreenService — never a hard-coded width in TypeScript or a breakpoint through Tailwind."],"notFor":["Anything visible; a second instance."],"shownIn":[{"story":"Layout/Media Screen/MediaScreen"},{"file":"apps/website/src/app/app.component.html"}],"sources":["libs/ui/src/lib/layout/media-screen/docs.mdx","media CLAUDE.md (own repo): breakpoints never go through Tailwind"],"reviewed":"592c82aa"}')},"./libs/ui/guide/ui-layout-nav.json"(module){"use strict";module.exports=JSON.parse('{"component":"ui-layout-nav","useFor":["The app navigation in the main header, fed by UiLayoutNavService — tab theme for a site, app theme with a home button for a tool."],"notFor":["A second nav in the same layout.","A menu in a drawer — that is the burger recipe with ui-layout-overlay."],"instead":["ui-layout-overlay"],"shownIn":[{"story":"Layout/Nav/TemplateTab"},{"story":"Layout/Nav/TemplateApp"},{"story":"Examples/Layout/Layout"},{"file":"apps/website/src/app/parts/header/header.component.html"}],"sources":["libs/ui/src/lib/layout/nav/docs.mdx"],"reviewed":"69197b72"}')},"./libs/ui/guide/ui-layout-overlay-header.json"(module){"use strict";module.exports=JSON.parse('{"component":"ui-layout-overlay-header","useFor":["The plain header of an overlay: headline plus close, in the overlay-header slot."],"notFor":["A header with anything else in it — write your own bar into the same slot. The media record sheet does, because its close turns into a two-step discard."],"shownIn":[{"story":"Layout/Overlay Header/InsideAnOverlay"},{"story":"Examples/Burger Menu/BurgerMenu"},{"file":"apps/website/src/app/app.component.html"}],"sources":["libs/ui/src/lib/layout/overlay/header/docs.mdx"],"reviewed":"592c82aa"}')},"./libs/ui/guide/ui-layout-overlay.json"(module){"use strict";module.exports=JSON.parse('{"component":"ui-layout-overlay","useFor":["A drawer or a modal over the page — a burger menu, a sign-in sheet, a record editor. Place it at the app\'s top level next to the layout, bind active in and take activeOutput back."],"notFor":["Anything inside the layout tree.","A tooltip or a popover."],"shownIn":[{"story":"Examples/Burger Menu/BurgerMenu"},{"story":"Layout/Overlay/Overlay"},{"story":"Layout/Overlay/ScrollContainment"},{"file":"apps/website/src/app/app.component.html"}],"sources":["libs/ui/src/lib/layout/overlay/docs.mdx","libs/ui/src/lib/examples/docs.mdx"],"reviewed":"592c82aa"}')},"./libs/ui/guide/ui-layout-spinner.json"(module){"use strict";module.exports=JSON.parse('{"component":"ui-layout-spinner","useFor":["The one global loading indicator at the app root, driven by UiLayoutSpinnerService from an HTTP interceptor."],"notFor":["A component\'s own loading state — that is ui-inline-spinner, which sits in the flow and blocks nothing; the table wrapper brings its own skeleton."],"shownIn":[{"story":"Layout/Spinner/Spinner"},{"file":"apps/website/src/app/app.component.html"}],"sources":["libs/ui/src/lib/layout/spinner/docs.mdx"],"reviewed":"8e6e0c56"}')},"./libs/ui/guide/ui-layout-splitter.json"(module){"use strict";module.exports=JSON.parse('{"component":"ui-layout-splitter","useFor":["A working view with two panes and an action header. The media editor is one: table left, detail right, and the zoom is the handle that widens the table."],"notFor":["Moving items between two lists.","Resizing panes by dragging — it has direction, zoom and fullscreen, no drag handle."],"instead":["ui-cdk-drag-drop-splitter"],"shownIn":[{"story":"Layout/Splitter/Splitter"},{"story":"Examples/Layout/Layout"}],"sources":["libs/ui/src/lib/layout/splitter/docs.mdx","media CLAUDE.md (own repo): the 4K table shots and the zoom"],"reviewed":"69197b72"}')},"./libs/ui/guide/ui-layout-tabs.json"(module){"use strict";module.exports=JSON.parse('{"component":"ui-layout-tabs","useFor":["A few sections of one view switched in place, inside a pane."],"notFor":["Routing between pages.","Remembering the active tab across a reload."],"shownIn":[{"story":"Layout/Tabs/TabsDefault"},{"story":"Examples/Layout/Layout"}],"sources":["libs/ui/src/lib/layout/tabs/docs.mdx"],"reviewed":"69197b72"}')},"./libs/ui/guide/ui-layout-top-scroll-bottom.json"(module){"use strict";module.exports=JSON.parse('{"component":"ui-layout-top-scroll-bottom","useFor":["A view whose middle scrolls while header and footer stay — once per route, inside main-content."],"notFor":["Anywhere outside ui-layout-main; a second one in the same view."],"shownIn":[{"story":"Layout/Top Scroll Bottom/TopScrollBottom"}],"sources":["libs/ui/src/lib/layout/top-scroll-bottom/docs.mdx"],"reviewed":"69197b72"}')},"./libs/ui/guide/ui-mosaic.json"(module){"use strict";module.exports=JSON.parse('{"component":"ui-mosaic","useFor":["A decorative tile field behind a page or over a picture — placed with CSS, given a box."],"notFor":["Anything clickable (pointer events are off).","An element in the flow without a height — it renders nothing, because its tile count comes from its box."],"shownIn":[{"story":"Atoms/Mosaic/Images"},{"story":"Atoms/Mosaic/OverImage"}],"sources":["libs/ui/src/lib/atoms/mosaic/docs.mdx"],"reviewed":"69197b72"}')},"./libs/ui/guide/ui-placeholder.json"(module){"use strict";module.exports=JSON.parse('{"component":"ui-placeholder","useFor":["Filler with visible mass in stories and examples, sized from the outside (class=\\"h-64\\") — so a reader can tell a stand-in from a component that failed to render."],"notFor":["Product UI. It is scenery for documentation."],"shownIn":[{"story":"Atoms/Placeholder/Sizes"},{"story":"Examples/Layout/Layout"}],"sources":["libs/ui/src/lib/atoms/placeholder/docs.mdx","agents.md (Storybook Guidelines: filler needs visible mass)"],"reviewed":"69197b72"}')},"./libs/ui/guide/ui-qr-code.json"(module){"use strict";module.exports=JSON.parse('{"component":"ui-qr-code","useFor":["A URL or a short text as a scannable code. M is the ordinary level; raise it for small prints or surfaces that get handled."],"notFor":["Payloads past the version-40 capacity at the chosen level; kanji or ECI encodings."],"shownIn":[{"story":"Atoms/QR Code/Default"},{"story":"Atoms/QR Code/Levels"}],"sources":["libs/ui/src/lib/atoms/qr-code/docs.mdx"],"reviewed":"69197b72"}')},"./libs/ui/guide/ui-rating.json"(module){"use strict";module.exports=JSON.parse('{"component":"ui-rating","useFor":["Displaying a rating as filled icons — read-only, any Material glyph, colours and size as CSS variables."],"notFor":["Collecting a rating: it takes no input from the reader."],"shownIn":[{"story":"Atoms/Rating/Rating"}],"sources":["libs/ui/src/lib/atoms/rating/docs.mdx"],"reviewed":"69197b72"}')},"./libs/ui/guide/ui-reader-doc.json"(module){"use strict";module.exports=JSON.parse('{"component":"ui-reader-doc","useFor":["Rendering a Markdown string in the house design — the website\'s content pages do. Whoever fetches, caches and picks the language stands in front of it."],"notFor":["Documents whose raw HTML must survive: it is discarded, counted and named on the page."],"shownIn":[{"story":"Atoms/ReaderDoc/Default"},{"story":"Atoms/ReaderDoc/DroppedMarkup"},{"story":"Atoms/ReaderDoc/Emphasis"},{"file":"apps/website/src/app/content/content.component.html"}],"sources":["libs/ui/src/lib/atoms/reader-doc/docs.mdx"],"reviewed":"2ae02124"}')},"./libs/ui/guide/ui-slider.json"(module){"use strict";module.exports=JSON.parse('{"component":"ui-slider","useFor":["A number or a min–max span the reader drags until it looks right."],"notFor":["A value the reader should type exactly — ui-input with type=\\"number\\"."],"instead":["ui-input"],"shownIn":[{"story":"Forms/Slider/Slider"},{"story":"Forms/Slider/Range"}],"sources":["libs/ui/src/lib/forms/slider/docs.mdx"],"reviewed":"69197b72"}')},"./libs/ui/guide/ui-switch.json"(module){"use strict";module.exports=JSON.parse('{"component":"ui-switch","useFor":["A deliberate on/off decision that takes effect at once and is valid either way — a setting, a filter, a mode."],"notFor":["A choice that can be required or invalid, such as a consent."],"instead":["ui-checkbox"],"shownIn":[{"story":"Forms/Switch/Switch"},{"story":"Styling/Forms/Forms"}],"sources":["libs/ui/src/lib/forms/switch/docs.mdx"],"reviewed":"69197b72"}')},"./libs/ui/guide/ui-text-animate.json"(module){"use strict";module.exports=JSON.parse('{"component":"ui-text-animate","useFor":["A headline that animates letter by letter; clip on the container when a variant travels in from outside."],"notFor":["Body text or anything longer than a phrase."],"shownIn":[{"story":"Atoms/Text Animate/TextAnimate"},{"file":"apps/change-me/src/app/slider/slider.component.html"}],"sources":["libs/ui/src/lib/atoms/text-animate/docs.mdx"],"reviewed":"69197b72"}')},"./libs/ui/guide/ui-thumb.json"(module){"use strict";module.exports=JSON.parse('{"component":"ui-thumb","useFor":["A linked preview image with a caption — playlist tiles, news, references on the website. Place it in a grid cell or give it a width."],"notFor":["A gallery of pictures sharing a selection.","An image without a link — a plain <img> does that."],"instead":["ui-image-grid"],"shownIn":[{"story":"Atoms/Thumb/Thumb"},{"story":"Atoms/Thumb/ThumbInternalLink"},{"file":"apps/website/src/app/content/youtube/youtube.component.html"},{"file":"apps/website/src/app/components/news/display/display.component.html"}],"sources":["libs/ui/src/lib/atoms/thumb/docs.mdx"],"reviewed":"69197b72"}')},"./libs/ui/guide/ui-timer.json"(module){"use strict";module.exports=JSON.parse('{"component":"ui-timer","useFor":["A countdown with a finished event; project the words that stand at zero, in your language."],"notFor":["Showing the time of day."],"instead":["ui-clock"],"shownIn":[{"story":"Atoms/Timer/Timer"}],"sources":["libs/ui/src/lib/atoms/timer/docs.mdx"],"reviewed":"69197b72"}')},"./libs/ui/guide/ui-typewriter.json"(module){"use strict";module.exports=JSON.parse('{"component":"ui-typewriter","useFor":["A line of text that types itself, optionally with a keystroke sound — the website\'s platformer intro."],"notFor":["Body text; a loop — a second sentence is a new run."],"shownIn":[{"story":"Atoms/Typewriter/Typewriter"},{"file":"apps/website/src/app/components/platformer/platformer.component.html"}],"sources":["libs/ui/src/lib/atoms/typewriter/docs.mdx"],"reviewed":"69197b72"}')}}]);
@@ -0,0 +1,2 @@
1
+ /*! For license information please see 9045.46ed3f61.iframe.bundle.js.LICENSE.txt */
2
+ (self.webpackChunkmoja_work=self.webpackChunkmoja_work||[]).push([[9045],{"./node_modules/@angular/core/fesm2022/rxjs-interop.mjs"(__unused_webpack_module,__webpack_exports__,__webpack_require__){"use strict";__webpack_require__.d(__webpack_exports__,{br:()=>toObservable,ot:()=>toSignal,pQ:()=>takeUntilDestroyed});var rxjs__WEBPACK_IMPORTED_MODULE_0__=__webpack_require__("./node_modules/rxjs/dist/esm5/internal/Observable.js"),rxjs__WEBPACK_IMPORTED_MODULE_1__=__webpack_require__("./node_modules/rxjs/dist/esm5/internal/ReplaySubject.js"),rxjs_operators__WEBPACK_IMPORTED_MODULE_2__=__webpack_require__("./node_modules/rxjs/dist/esm5/internal/operators/takeUntil.js"),_effect_chunk2_mjs__WEBPACK_IMPORTED_MODULE_3__=__webpack_require__("./node_modules/@angular/core/fesm2022/_effect-chunk2.mjs"),_resource_chunk_mjs__WEBPACK_IMPORTED_MODULE_4__=__webpack_require__("./node_modules/@angular/core/fesm2022/_resource-chunk.mjs");function takeUntilDestroyed(destroyRef){destroyRef||(ngDevMode&&(0,_effect_chunk2_mjs__WEBPACK_IMPORTED_MODULE_3__.Af3)(takeUntilDestroyed),destroyRef=(0,_effect_chunk2_mjs__WEBPACK_IMPORTED_MODULE_3__.WQX)(_effect_chunk2_mjs__WEBPACK_IMPORTED_MODULE_3__.abz));const destroyed$=new rxjs__WEBPACK_IMPORTED_MODULE_0__.c(subscriber=>{if(destroyRef.destroyed)return void subscriber.next();return destroyRef.onDestroy(subscriber.next.bind(subscriber))});return source=>source.pipe((0,rxjs_operators__WEBPACK_IMPORTED_MODULE_2__.Q)(destroyed$))}function toObservable(source,options){ngDevMode&&!options?.injector&&(0,_effect_chunk2_mjs__WEBPACK_IMPORTED_MODULE_3__.Af3)(toObservable);const injector=options?.injector??(0,_effect_chunk2_mjs__WEBPACK_IMPORTED_MODULE_3__.WQX)(_effect_chunk2_mjs__WEBPACK_IMPORTED_MODULE_3__.zZn),subject=new rxjs__WEBPACK_IMPORTED_MODULE_1__.m(1),watcher=(0,_effect_chunk2_mjs__WEBPACK_IMPORTED_MODULE_3__.QZP)(()=>{let value;try{value=source()}catch(err){return void(0,_resource_chunk_mjs__WEBPACK_IMPORTED_MODULE_4__.O8)(()=>subject.error(err))}(0,_resource_chunk_mjs__WEBPACK_IMPORTED_MODULE_4__.O8)(()=>subject.next(value))},{injector,manualCleanup:!0});return injector.get(_effect_chunk2_mjs__WEBPACK_IMPORTED_MODULE_3__.abz).onDestroy(()=>{watcher.destroy(),subject.complete()}),subject.asObservable()}function toSignal(source,options){"undefined"!=typeof ngDevMode&&ngDevMode&&(0,_effect_chunk2_mjs__WEBPACK_IMPORTED_MODULE_3__.tdH)(toSignal,"Invoking `toSignal` causes new subscriptions every time. Consider moving `toSignal` outside of the reactive context and read the signal value where needed.");const requiresCleanup=!options?.manualCleanup;ngDevMode&&requiresCleanup&&!options?.injector&&(0,_effect_chunk2_mjs__WEBPACK_IMPORTED_MODULE_3__.Af3)(toSignal);const cleanupRef=requiresCleanup?options?.injector?.get(_effect_chunk2_mjs__WEBPACK_IMPORTED_MODULE_3__.abz)??(0,_effect_chunk2_mjs__WEBPACK_IMPORTED_MODULE_3__.WQX)(_effect_chunk2_mjs__WEBPACK_IMPORTED_MODULE_3__.abz):null,equal=function makeToSignalEqual(userEquality=Object.is){return(a,b)=>1===a.kind&&1===b.kind&&userEquality(a.value,b.value)}(options?.equal);let state,destroyUnregisterFn;state=options?.requireSync?(0,_effect_chunk2_mjs__WEBPACK_IMPORTED_MODULE_3__.vPA)({kind:0},{equal,...ngDevMode?createDebugNameObject(options?.debugName,"state"):void 0}):(0,_effect_chunk2_mjs__WEBPACK_IMPORTED_MODULE_3__.vPA)({kind:1,value:options?.initialValue},{equal,...ngDevMode?createDebugNameObject(options?.debugName,"state"):void 0});const sub=source.subscribe({next:value=>state.set({kind:1,value}),error:error=>{state.set({kind:2,error}),destroyUnregisterFn?.()},complete:()=>{destroyUnregisterFn?.()}});if(options?.requireSync&&0===state().kind)throw new _effect_chunk2_mjs__WEBPACK_IMPORTED_MODULE_3__.buA(601,("undefined"==typeof ngDevMode||ngDevMode)&&"`toSignal()` called with `requireSync` but `Observable` did not emit synchronously.");return destroyUnregisterFn=cleanupRef?.onDestroy(sub.unsubscribe.bind(sub)),(0,_resource_chunk_mjs__WEBPACK_IMPORTED_MODULE_4__.EW)(()=>{const current=state();switch(current.kind){case 1:return current.value;case 2:throw current.error;case 0:throw new _effect_chunk2_mjs__WEBPACK_IMPORTED_MODULE_3__.buA(601,("undefined"==typeof ngDevMode||ngDevMode)&&"`toSignal()` called with `requireSync` but `Observable` did not emit synchronously.")}},{equal:options?.equal,...ngDevMode?createDebugNameObject(options?.debugName,"source"):void 0})}function createDebugNameObject(toSignalDebugName,internalSignalDebugName){return{debugName:`toSignal${toSignalDebugName?"#"+toSignalDebugName:""}.${internalSignalDebugName}`}}},"./libs/ui/.storybook/demos/header/header.component.ts"(__unused_webpack_module,__webpack_exports__,__webpack_require__){"use strict";__webpack_require__.d(__webpack_exports__,{b:()=>UiInternHeaderComponent});var tslib_es6=__webpack_require__("./node_modules/tslib/tslib.es6.mjs");var header_componentngResource=__webpack_require__("./libs/ui/.storybook/demos/header/header.component.css?ngResource"),header_componentngResource_default=__webpack_require__.n(header_componentngResource),_common_module_chunk=__webpack_require__("./node_modules/@angular/common/fesm2022/_common_module-chunk.mjs"),_effect_chunk2=__webpack_require__("./node_modules/@angular/core/fesm2022/_effect-chunk2.mjs"),core=__webpack_require__("./node_modules/@angular/core/fesm2022/core.mjs"),_debug_node_chunk=__webpack_require__("./node_modules/@angular/core/fesm2022/_debug_node-chunk.mjs"),ui_config_types=__webpack_require__("./libs/ui/src/config/ui-config.types.ts"),layout_service=__webpack_require__("./libs/ui/src/lib/layout/_service/layout.service.ts");let UiInternHeaderComponent=class UiInternHeaderComponent{layoutService=(0,_effect_chunk2.WQX)(layout_service.u);theme=(0,core.input)(null);display=(0,core.input)(!1,{transform:core.booleanAttribute});onTop=(0,core.input)(!1,{transform:core.booleanAttribute});ngOnInit(){this.layoutService.handleTheme(this.theme(),ui_config_types.Q)}ngOnDestroy(){this.layoutService.handleTheme("theme-light",ui_config_types.Q)}setTheme(){this.layoutService.handleTheme(null,ui_config_types.Q)}static propDecorators={theme:[{type:_debug_node_chunk.pde,args:[{isSignal:!0,alias:"theme",required:!1,transform:void 0}]}],display:[{type:_debug_node_chunk.pde,args:[{isSignal:!0,alias:"display",required:!1,transform:void 0}]}],onTop:[{type:_debug_node_chunk.pde,args:[{isSignal:!0,alias:"onTop",required:!1,transform:void 0}]}]}};UiInternHeaderComponent=(0,tslib_es6.Cg)([(0,_debug_node_chunk.uAl)({selector:"ui-intern-header",template:'@if (display()) {\n <button class="ui" [class._on-top]="onTop()" (click)="setTheme()">\n switch Theme\n </button>\n}\n',encapsulation:_debug_node_chunk.gXe.Emulated,standalone:!0,imports:[_common_module_chunk.MD],styles:[header_componentngResource_default()]})],UiInternHeaderComponent)},"./libs/ui/src/config/ui-config.types.ts"(__unused_webpack_module,__webpack_exports__,__webpack_require__){"use strict";__webpack_require__.d(__webpack_exports__,{Q:()=>uiConfigStorybookCssPrefix,y:()=>uiConfigTypes});const uiConfigStorybookCssPrefix="ui-storybook ",uiConfigTypes={mainID:"ui-main",mainClass:"ui-main",storeName:"ui-layout"}},"./libs/ui/src/lib/atoms/image.mock.ts"(__unused_webpack_module,__webpack_exports__,__webpack_require__){"use strict";function uiImageMock(){const mock=Array.from({length:25},(_,index)=>({title:`Number: ${index+1}`,alt:`number-${index+1}`,src:{default:`https://moja.work/content/_assets/pictures/numbers/10/numbers-0${String(index+1).padStart(2,"0")}.png`,medium:`https://moja.work/content/_assets/pictures/numbers/25/numbers-0${String(index+1).padStart(2,"0")}.png`,max:`https://moja.work/content/_assets/pictures/numbers/50/numbers-0${String(index+1).padStart(2,"0")}.png`}}));return mock[3].src.default="",mock[3].src.medium="",mock[3].src.max="",mock[3].title="no image on purpose",mock[3].alt="number-4, no image",mock}__webpack_require__.d(__webpack_exports__,{W:()=>uiImageMock})},"./libs/ui/src/lib/helpers/resize-signal.ts"(__unused_webpack_module,__webpack_exports__,__webpack_require__){"use strict";__webpack_require__.d(__webpack_exports__,{H:()=>uiResizeSignal});var rxjs_interop=__webpack_require__("./node_modules/@angular/core/fesm2022/rxjs-interop.mjs"),fromEvent=__webpack_require__("./node_modules/rxjs/dist/esm5/internal/observable/fromEvent.js"),scheduler_async=__webpack_require__("./node_modules/rxjs/dist/esm5/internal/scheduler/async.js"),lift=__webpack_require__("./node_modules/rxjs/dist/esm5/internal/util/lift.js"),OperatorSubscriber=__webpack_require__("./node_modules/rxjs/dist/esm5/internal/operators/OperatorSubscriber.js"),innerFrom=__webpack_require__("./node_modules/rxjs/dist/esm5/internal/observable/innerFrom.js");var timer=__webpack_require__("./node_modules/rxjs/dist/esm5/internal/observable/timer.js");function throttleTime(duration,scheduler,config){void 0===scheduler&&(scheduler=scheduler_async.E);var duration$=(0,timer.O)(duration,scheduler);return function throttle(durationSelector,config){return(0,lift.N)(function(source,subscriber){var _a=null!=config?config:{},_b=_a.leading,leading=void 0===_b||_b,_c=_a.trailing,trailing=void 0!==_c&&_c,hasValue=!1,sendValue=null,throttled=null,isComplete=!1,endThrottling=function(){null==throttled||throttled.unsubscribe(),throttled=null,trailing&&(send(),isComplete&&subscriber.complete())},cleanupThrottling=function(){throttled=null,isComplete&&subscriber.complete()},startThrottle=function(value){return throttled=(0,innerFrom.Tg)(durationSelector(value)).subscribe((0,OperatorSubscriber._)(subscriber,endThrottling,cleanupThrottling))},send=function(){if(hasValue){hasValue=!1;var value=sendValue;sendValue=null,subscriber.next(value),!isComplete&&startThrottle(value)}};source.subscribe((0,OperatorSubscriber._)(subscriber,function(value){hasValue=!0,sendValue=value,(!throttled||throttled.closed)&&(leading?send():startThrottle(value))},function(){isComplete=!0,(!(trailing&&hasValue&&throttled)||throttled.closed)&&subscriber.complete()}))})}(function(){return duration$},config)}function uiResizeSignal(throttle=100){return(0,rxjs_interop.ot)((0,fromEvent.R)(window,"resize").pipe(throttleTime(throttle)))}},"./libs/ui/src/lib/layout/_service/layout.service.ts"(__unused_webpack_module,__webpack_exports__,__webpack_require__){"use strict";__webpack_require__.d(__webpack_exports__,{u:()=>UiLayoutService});var tslib__WEBPACK_IMPORTED_MODULE_0__=__webpack_require__("./node_modules/tslib/tslib.es6.mjs"),_angular_core__WEBPACK_IMPORTED_MODULE_1__=__webpack_require__("./node_modules/@angular/core/fesm2022/_debug_node-chunk.mjs"),_angular_core__WEBPACK_IMPORTED_MODULE_2__=__webpack_require__("./node_modules/@angular/core/fesm2022/_effect-chunk2.mjs"),_ngx_pwa_local_storage__WEBPACK_IMPORTED_MODULE_3__=__webpack_require__("./node_modules/@ngx-pwa/local-storage/fesm2022/ngx-pwa-local-storage.mjs"),_config_ui_config_types__WEBPACK_IMPORTED_MODULE_4__=__webpack_require__("./libs/ui/src/config/ui-config.types.ts");let UiLayoutService=class UiLayoutService{storage=(0,_angular_core__WEBPACK_IMPORTED_MODULE_2__.WQX)(_ngx_pwa_local_storage__WEBPACK_IMPORTED_MODULE_3__.AX);settings={cssPrefix:"",theme:null,zoom:null,fullscreen:null,direction:"center",layoutSize:null};setStorage(){this.storage.set(_config_ui_config_types__WEBPACK_IMPORTED_MODULE_4__.y.storeName,this.settings).subscribe()}handleInit(config){this.settings.cssPrefix=config.cssPrefix,this.settings.theme=config.theme,this.settings.zoom=config.zoom?"zoom":"x-zoom",this.settings.fullscreen=config.fullscreen?"fullscreen":"x-fullscreen",this.handleFullScreen(this.settings.fullscreen),this.storage.get(_config_ui_config_types__WEBPACK_IMPORTED_MODULE_4__.y.storeName).subscribe(data=>{data&&(this.settings=data),this.setStorage(),this.setTheme(null)})}setTheme(theme){document.body.className=theme?`${this.settings.cssPrefix} ${theme}`:`${this.settings.cssPrefix} ${this.settings.theme}`}getTheme(){return this.storage.get(_config_ui_config_types__WEBPACK_IMPORTED_MODULE_4__.y.storeName).subscribe(data=>{data&&(this.settings=data)}),this.settings.theme}getMainClass(){return`${_config_ui_config_types__WEBPACK_IMPORTED_MODULE_4__.y.mainClass} ${this.settings.zoom} ${this.settings.fullscreen}`}handleFullScreen(init){init?this.settings.fullscreen=init:"fullscreen"===this.settings.fullscreen?this.settings.fullscreen="x-fullscreen":this.settings.fullscreen="fullscreen",this.setStorage()}handleZoom(init){init?this.settings.zoom=init:"zoom"===this.settings.zoom?this.settings.zoom="x-zoom":this.settings.zoom="zoom",this.setStorage()}handleTheme(theme,prefix){return prefix&&(this.settings.cssPrefix=prefix),theme?(this.setTheme(theme),this.settings.theme=theme):(this.settings.theme="theme-light"===this.settings.theme?"theme-dark":"theme-light",this.setTheme(null)),this.setStorage(),this.settings.theme}handleDirection(type){this.settings.direction=type,this.setStorage()}setLayoutSize(sizes){this.settings.layoutSize=sizes,this.storage.set(_config_ui_config_types__WEBPACK_IMPORTED_MODULE_4__.y.storeName,this.settings).subscribe()}getLayoutSize(){return this.storage.get(_config_ui_config_types__WEBPACK_IMPORTED_MODULE_4__.y.storeName).subscribe(data=>{data&&(this.settings=data)}),this.settings.layoutSize}};UiLayoutService=(0,tslib__WEBPACK_IMPORTED_MODULE_0__.Cg)([(0,_angular_core__WEBPACK_IMPORTED_MODULE_1__._qm)({providedIn:"root"})],UiLayoutService)},"./node_modules/rxjs/dist/esm5/internal/operators/takeUntil.js"(__unused_webpack_module,__webpack_exports__,__webpack_require__){"use strict";__webpack_require__.d(__webpack_exports__,{Q:()=>takeUntil});var _util_lift__WEBPACK_IMPORTED_MODULE_0__=__webpack_require__("./node_modules/rxjs/dist/esm5/internal/util/lift.js"),_OperatorSubscriber__WEBPACK_IMPORTED_MODULE_1__=__webpack_require__("./node_modules/rxjs/dist/esm5/internal/operators/OperatorSubscriber.js"),_observable_innerFrom__WEBPACK_IMPORTED_MODULE_2__=__webpack_require__("./node_modules/rxjs/dist/esm5/internal/observable/innerFrom.js"),_util_noop__WEBPACK_IMPORTED_MODULE_3__=__webpack_require__("./node_modules/rxjs/dist/esm5/internal/util/noop.js");function takeUntil(notifier){return(0,_util_lift__WEBPACK_IMPORTED_MODULE_0__.N)(function(source,subscriber){(0,_observable_innerFrom__WEBPACK_IMPORTED_MODULE_2__.Tg)(notifier).subscribe((0,_OperatorSubscriber__WEBPACK_IMPORTED_MODULE_1__._)(subscriber,function(){return subscriber.complete()},_util_noop__WEBPACK_IMPORTED_MODULE_3__.l)),!subscriber.closed&&source.subscribe(subscriber)})}},"./libs/ui/.storybook/demos/header/header.component.css?ngResource"(module,__unused_webpack_exports,__webpack_require__){var ___CSS_LOADER_API_NO_SOURCEMAP_IMPORT___=__webpack_require__("./node_modules/css-loader/dist/runtime/noSourceMaps.js"),___CSS_LOADER_EXPORT___=__webpack_require__("./node_modules/css-loader/dist/runtime/api.js")(___CSS_LOADER_API_NO_SOURCEMAP_IMPORT___);___CSS_LOADER_EXPORT___.push([module.id,"/* The intern header is reduced to just the theme switch button, pinned to the */\n/* bottom-left corner of the Storybook canvas. */\nbutton {\n position: fixed;\n bottom: calc(var(--ui-spacer) * 0.5);\n left: calc(var(--ui-spacer) * 0.5);\n z-index: 1000;\n\n &._on-top {\n z-index: 10000;\n }\n}\n",""]),module.exports=___CSS_LOADER_EXPORT___.toString()}}]);
@@ -1 +1 @@
1
- "use strict";(self.webpackChunkmoja_work=self.webpackChunkmoja_work||[]).push([[1365,3260],{"./libs/ui/src/lib/_external/mwork-music-player/docs.mdx"(__unused_webpack_module,__webpack_exports__,__webpack_require__){__webpack_require__.r(__webpack_exports__),__webpack_require__.d(__webpack_exports__,{default:()=>MDXContent});__webpack_require__("./node_modules/react/index.js");var react_jsx_runtime__WEBPACK_IMPORTED_MODULE_1__=__webpack_require__("./node_modules/react/jsx-runtime.js"),file_Users_moja_projects_mojawork_mono_node_modules_storybook_addon_docs_dist_mdx_react_shim_js__WEBPACK_IMPORTED_MODULE_2__=__webpack_require__("./node_modules/@mdx-js/react/lib/index.js"),_storybook_addon_docs_blocks__WEBPACK_IMPORTED_MODULE_3__=__webpack_require__("./node_modules/@storybook/addon-docs/dist/blocks.js"),_mwork_music_player_stories__WEBPACK_IMPORTED_MODULE_4__=__webpack_require__("./libs/ui/src/lib/_external/mwork-music-player/mwork-music-player.stories.ts");function _createMdxContent(props){const _components={code:"code",h3:"h3",h4:"h4",hr:"hr",p:"p",pre:"pre",...(0,file_Users_moja_projects_mojawork_mono_node_modules_storybook_addon_docs_dist_mdx_react_shim_js__WEBPACK_IMPORTED_MODULE_2__.R)(),...props.components};return(0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_1__.jsxs)(react_jsx_runtime__WEBPACK_IMPORTED_MODULE_1__.Fragment,{children:[(0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_1__.jsx)(_storybook_addon_docs_blocks__WEBPACK_IMPORTED_MODULE_3__.W8,{of:_mwork_music_player_stories__WEBPACK_IMPORTED_MODULE_4__}),"\n",(0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_1__.jsx)(_components.h3,{id:"external-mwork-music-player",children:"External: Mwork Music Player"}),"\n",(0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_1__.jsxs)(_components.p,{children:[(0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_1__.jsx)(_components.code,{children:"<mwork-music-player>"})," is a minimal music player as a framework-agnostic web component\n(Stencil, from the ",(0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_1__.jsx)(_components.code,{children:"web-components"})," repo, published as ",(0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_1__.jsx)(_components.code,{children:"@mojawork/web-components"}),"). It wraps\na native ",(0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_1__.jsx)(_components.code,{children:"<audio>"})," element with playlist buttons, prev/next/play/pause controls and a\nmetadata section that fetches the active track and displays its ID3 tags — title, album,\nartist and embedded cover, plus the full format and generic tag tables (parsed with\n",(0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_1__.jsx)(_components.code,{children:"music-metadata"}),", the package's only runtime dependency)."]}),"\n",(0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_1__.jsx)(_components.p,{children:"The playlist is fully consumer-provided: the component ships without any built-in URLs.\nThe playlist below is a demo configured in this story."}),"\n",(0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_1__.jsx)(_storybook_addon_docs_blocks__WEBPACK_IMPORTED_MODULE_3__.Hl,{of:_mwork_music_player_stories__WEBPACK_IMPORTED_MODULE_4__.Default}),"\n",(0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_1__.jsx)(_components.hr,{}),"\n",(0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_1__.jsx)(_components.h4,{id:"properties",children:"Properties"}),"\n",(0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_1__.jsxs)("table",{class:"ui",children:[(0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_1__.jsxs)("tr",{children:[(0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_1__.jsx)("th",{style:{width:"14rem"},children:"Property / attribute"}),(0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_1__.jsx)("th",{style:{width:"10rem"},children:"Type"}),(0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_1__.jsx)("th",{style:{width:"8rem"},children:"Default"}),(0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_1__.jsx)("th",{children:"Description"})]}),(0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_1__.jsxs)("tr",{children:[(0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_1__.jsx)("td",{children:(0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_1__.jsx)("code",{children:"tracks"})}),(0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_1__.jsx)("td",{children:(0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_1__.jsx)("code",{children:"string[] | string"})}),(0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_1__.jsx)("td",{children:(0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_1__.jsx)("code",{children:"[]"})}),(0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_1__.jsx)("td",{children:(0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_1__.jsxs)(_components.p,{children:["The playlist. As a property a real string array; as an attribute a JSON array string\n(",(0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_1__.jsx)("code",{children:'\'["a.mp3","b.mp3"]\''}),") or a comma/newline separated list of URLs."]})})]}),(0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_1__.jsxs)("tr",{children:[(0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_1__.jsxs)("td",{children:[(0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_1__.jsx)("code",{children:"show-meta"})," / ",(0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_1__.jsx)("code",{children:"showMeta"})]}),(0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_1__.jsx)("td",{children:(0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_1__.jsx)("code",{children:"boolean"})}),(0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_1__.jsx)("td",{children:(0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_1__.jsx)("code",{children:"true"})}),(0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_1__.jsx)("td",{children:"Show the metadata section (cover and tag tables) below the controls."})]})]}),"\n",(0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_1__.jsx)(_components.h4,{id:"events",children:"Events"}),"\n",(0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_1__.jsxs)("table",{class:"ui",children:[(0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_1__.jsxs)("tr",{children:[(0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_1__.jsx)("th",{style:{width:"14rem"},children:"Event"}),(0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_1__.jsx)("th",{children:"Payload"})]}),(0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_1__.jsxs)("tr",{children:[(0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_1__.jsx)("td",{children:(0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_1__.jsx)("code",{children:"mworkTrackChange"})}),(0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_1__.jsx)("td",{children:(0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_1__.jsxs)(_components.p,{children:[(0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_1__.jsx)("code",{children:"{ index: number, url: string }"})," — fired whenever the active\ntrack changes, including the initial track."]})})]}),(0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_1__.jsxs)("tr",{children:[(0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_1__.jsx)("td",{children:(0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_1__.jsx)("code",{children:"mworkMusicMeta"})}),(0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_1__.jsx)("td",{children:(0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_1__.jsxs)(_components.p,{children:["Essential metadata after a successful parse: ",(0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_1__.jsx)("code",{children:"title"}),", ",(0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_1__.jsx)("code",{children:"track"}),",\n",(0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_1__.jsx)("code",{children:"album"}),", ",(0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_1__.jsx)("code",{children:"artist"}),", ",(0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_1__.jsx)("code",{children:"image"})," (base64 data URL of the\ncover) and ",(0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_1__.jsx)("code",{children:"url"}),"."]})})]})]}),"\n",(0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_1__.jsx)(_components.h4,{id:"methods",children:"Methods"}),"\n",(0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_1__.jsxs)("table",{class:"ui",children:[(0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_1__.jsxs)("tr",{children:[(0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_1__.jsx)("th",{style:{width:"14rem"},children:"Method"}),(0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_1__.jsx)("th",{children:"Effect"})]}),(0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_1__.jsxs)("tr",{children:[(0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_1__.jsxs)("td",{children:[(0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_1__.jsx)("code",{children:"play()"})," / ",(0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_1__.jsx)("code",{children:"pause()"})]}),(0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_1__.jsx)("td",{children:"Start or pause playback of the loaded track."})]}),(0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_1__.jsxs)("tr",{children:[(0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_1__.jsxs)("td",{children:[(0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_1__.jsx)("code",{children:"prev()"})," / ",(0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_1__.jsx)("code",{children:"next()"})]}),(0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_1__.jsx)("td",{children:"Move through the playlist (no-ops at the first/last track)."})]}),(0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_1__.jsxs)("tr",{children:[(0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_1__.jsx)("td",{children:(0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_1__.jsx)("code",{children:"selectTrack(index)"})}),(0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_1__.jsx)("td",{children:"Load and play the track at the given playlist index."})]})]}),"\n",(0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_1__.jsx)(_components.hr,{}),"\n",(0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_1__.jsx)(_components.h4,{id:"variants",children:"Variants"}),"\n",(0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_1__.jsxs)(_components.p,{children:["Without the metadata section (",(0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_1__.jsx)("code",{children:'show-meta="false"'}),"):"]}),"\n",(0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_1__.jsx)(_storybook_addon_docs_blocks__WEBPACK_IMPORTED_MODULE_3__.Hl,{of:_mwork_music_player_stories__WEBPACK_IMPORTED_MODULE_4__.WithoutMeta}),"\n",(0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_1__.jsx)(_components.p,{children:"A single track hides the playlist buttons:"}),"\n",(0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_1__.jsx)(_storybook_addon_docs_blocks__WEBPACK_IMPORTED_MODULE_3__.Hl,{of:_mwork_music_player_stories__WEBPACK_IMPORTED_MODULE_4__.SingleTrack}),"\n",(0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_1__.jsx)(_components.hr,{}),"\n",(0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_1__.jsx)(_components.h4,{id:"theming",children:"Theming"}),"\n",(0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_1__.jsxs)(_components.p,{children:["The player is styled exclusively through its own ",(0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_1__.jsx)("code",{children:"--mwork-player-*"})," CSS custom\nproperties, each with a working default — it needs no surrounding design system and stays\nindependent of the ui library. Apps map their tokens onto them; this story maps the ui\ndesign tokens (theme-aware, so it follows light/dark):"]}),"\n",(0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_1__.jsx)(_components.pre,{children:(0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_1__.jsx)(_components.code,{className:"language-css",children:"mwork-music-player {\n --mwork-player-color: var(--ui-c-default);\n --mwork-player-background: var(--ui-c-background);\n --mwork-player-spacer: var(--ui-spacer);\n --mwork-player-border-width: var(--ui-border-width);\n --mwork-player-border-color: var(--ui-c-fourthly);\n --mwork-player-border-radius: var(--ui-border-radius);\n --mwork-player-accent: var(--ui-c-primary);\n --mwork-player-accent-contrast: var(--ui-c-invert);\n --mwork-player-error-color: var(--ui-c-error);\n}\n"})}),"\n",(0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_1__.jsx)(_storybook_addon_docs_blocks__WEBPACK_IMPORTED_MODULE_3__.Hl,{of:_mwork_music_player_stories__WEBPACK_IMPORTED_MODULE_4__.UiThemed}),"\n",(0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_1__.jsxs)(_components.p,{children:["Additional knobs: ",(0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_1__.jsx)("code",{children:"--mwork-player-font-family"}),",\n",(0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_1__.jsx)("code",{children:"--mwork-player-button-background"})," and ",(0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_1__.jsx)("code",{children:"--mwork-player-cover-size"}),"\n(default ",(0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_1__.jsx)("code",{children:"16rem"}),")."]}),"\n",(0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_1__.jsx)(_components.hr,{}),"\n",(0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_1__.jsx)(_components.h4,{id:"usage-in-an-app",children:"Usage in an app"}),"\n",(0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_1__.jsx)(_components.pre,{children:(0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_1__.jsx)(_components.code,{className:"language-bash",children:"npm i @mojawork/web-components\n"})}),"\n",(0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_1__.jsx)(_components.pre,{children:(0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_1__.jsx)(_components.code,{className:"language-ts",children:"// main.ts — registers all mwork components once\nimport { defineCustomElements } from '@mojawork/web-components/loader';\ndefineCustomElements();\n"})}),"\n",(0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_1__.jsx)(_components.pre,{children:(0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_1__.jsx)(_components.code,{className:"language-html",children:'<mwork-music-player\n tracks=\'["https://moja.work/one.mp3", "https://moja.work/two.mp3"]\'\n></mwork-music-player>\n'})}),"\n",(0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_1__.jsxs)(_components.p,{children:["In Angular templates, bind the playlist as a property (requires\n",(0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_1__.jsx)("code",{children:"CUSTOM_ELEMENTS_SCHEMA"}),"): ",(0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_1__.jsx)("code",{children:'[tracks]="trackUrls"'}),"."]})]})}function MDXContent(props={}){const{wrapper:MDXLayout}={...(0,file_Users_moja_projects_mojawork_mono_node_modules_storybook_addon_docs_dist_mdx_react_shim_js__WEBPACK_IMPORTED_MODULE_2__.R)(),...props.components};return MDXLayout?(0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_1__.jsx)(MDXLayout,{...props,children:(0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_1__.jsx)(_createMdxContent,{...props})}):_createMdxContent(props)}},"./libs/ui/src/lib/_external/mwork-music-player/mwork-music-player.stories.ts"(__unused_webpack_module,__webpack_exports__,__webpack_require__){__webpack_require__.r(__webpack_exports__),__webpack_require__.d(__webpack_exports__,{Default:()=>Default,SingleTrack:()=>SingleTrack,UiThemed:()=>UiThemed,WithoutMeta:()=>WithoutMeta,__namedExportsOrder:()=>__namedExportsOrder,default:()=>__WEBPACK_DEFAULT_EXPORT__});var _angular_core__WEBPACK_IMPORTED_MODULE_0__=__webpack_require__("./node_modules/@angular/core/fesm2022/_debug_node-chunk.mjs"),_storybook_angular__WEBPACK_IMPORTED_MODULE_1__=__webpack_require__("./node_modules/@storybook/angular/dist/index.js"),storybook_actions__WEBPACK_IMPORTED_MODULE_2__=__webpack_require__("storybook/actions");(0,__webpack_require__("../web-components/loader/index.js").u)();const DEMO_TRACKS=["https://moja.work/media/traks/mojawork-v1.mp3","https://moja.work/media/traks/mojawork-v2.mp3","https://moja.work/media/traks/mojawork-v3.mp3"],__WEBPACK_DEFAULT_EXPORT__={title:"External/Mwork Music Player",decorators:[(0,_storybook_angular__WEBPACK_IMPORTED_MODULE_1__.Iz)({schemas:[_angular_core__WEBPACK_IMPORTED_MODULE_0__.CkJ]})],argTypes:{tracks:{control:"object",description:"Playlist as an array of track URLs (property binding); as attribute also a JSON array string or a comma/newline separated list."},showMeta:{control:"boolean",description:"Show the ID3/format metadata section below the controls."},mworkTrackChange:{control:!1,description:"Emitted when the active track changes: { index, url }."},mworkMusicMeta:{control:!1,description:"Emitted after a successful metadata parse: title, track, album, artist, cover image, url."}},args:{tracks:DEMO_TRACKS,showMeta:!0},render:args=>({props:{...args,mworkTrackChange:(0,storybook_actions__WEBPACK_IMPORTED_MODULE_2__.action)("mworkTrackChange"),mworkMusicMeta:(0,storybook_actions__WEBPACK_IMPORTED_MODULE_2__.action)("mworkMusicMeta")},template:'\n <div class="flex justify-center p-4">\n <mwork-music-player\n class="w-full max-w-3xl"\n [tracks]="tracks"\n [showMeta]="showMeta"\n (mworkTrackChange)="mworkTrackChange($event)"\n (mworkMusicMeta)="mworkMusicMeta($event)"\n ></mwork-music-player>\n </div>\n '})},Default={},WithoutMeta={args:{showMeta:!1}},SingleTrack={args:{tracks:[DEMO_TRACKS[0]]}},UiThemed={render:args=>({props:{...args,mworkTrackChange:(0,storybook_actions__WEBPACK_IMPORTED_MODULE_2__.action)("mworkTrackChange"),mworkMusicMeta:(0,storybook_actions__WEBPACK_IMPORTED_MODULE_2__.action)("mworkMusicMeta")},template:'\n <style>\n .ui-themed-music-player {\n --mwork-player-font-family: inherit;\n --mwork-player-color: var(--ui-c-default);\n --mwork-player-background: var(--ui-c-background);\n --mwork-player-spacer: var(--ui-spacer);\n --mwork-player-border-width: var(--ui-border-width);\n --mwork-player-border-color: var(--ui-c-fourthly);\n --mwork-player-border-radius: var(--ui-border-radius);\n --mwork-player-accent: var(--ui-c-primary);\n --mwork-player-accent-contrast: var(--ui-c-invert);\n --mwork-player-error-color: var(--ui-c-error);\n }\n </style>\n <div class="flex justify-center p-4">\n <mwork-music-player\n class="ui-themed-music-player w-full max-w-3xl"\n [tracks]="tracks"\n [showMeta]="showMeta"\n (mworkTrackChange)="mworkTrackChange($event)"\n (mworkMusicMeta)="mworkMusicMeta($event)"\n ></mwork-music-player>\n </div>\n '})},__namedExportsOrder=["Default","WithoutMeta","SingleTrack","UiThemed"];Default.parameters={...Default.parameters,docs:{...Default.parameters?.docs,source:{originalSource:"{}",...Default.parameters?.docs?.source}}},WithoutMeta.parameters={...WithoutMeta.parameters,docs:{...WithoutMeta.parameters?.docs,source:{originalSource:"{\n args: {\n showMeta: false\n }\n}",...WithoutMeta.parameters?.docs?.source}}},SingleTrack.parameters={...SingleTrack.parameters,docs:{...SingleTrack.parameters?.docs,source:{originalSource:"{\n args: {\n tracks: [DEMO_TRACKS[0]]\n }\n}",...SingleTrack.parameters?.docs?.source}}},UiThemed.parameters={...UiThemed.parameters,docs:{...UiThemed.parameters?.docs,source:{originalSource:'{\n render: args => ({\n props: {\n ...args,\n mworkTrackChange: action(\'mworkTrackChange\'),\n mworkMusicMeta: action(\'mworkMusicMeta\')\n },\n template: `\n <style>\n .ui-themed-music-player {\n --mwork-player-font-family: inherit;\n --mwork-player-color: var(--ui-c-default);\n --mwork-player-background: var(--ui-c-background);\n --mwork-player-spacer: var(--ui-spacer);\n --mwork-player-border-width: var(--ui-border-width);\n --mwork-player-border-color: var(--ui-c-fourthly);\n --mwork-player-border-radius: var(--ui-border-radius);\n --mwork-player-accent: var(--ui-c-primary);\n --mwork-player-accent-contrast: var(--ui-c-invert);\n --mwork-player-error-color: var(--ui-c-error);\n }\n </style>\n <div class="flex justify-center p-4">\n <mwork-music-player\n class="ui-themed-music-player w-full max-w-3xl"\n [tracks]="tracks"\n [showMeta]="showMeta"\n (mworkTrackChange)="mworkTrackChange($event)"\n (mworkMusicMeta)="mworkMusicMeta($event)"\n ></mwork-music-player>\n </div>\n `\n })\n}',...UiThemed.parameters?.docs?.source},description:{story:"Maps the ui design tokens onto the component's own `--mwork-player-*`\ncustom properties — the pattern every ui app uses to theme the player.",...UiThemed.parameters?.docs?.description}}}}}]);
1
+ "use strict";(self.webpackChunkmoja_work=self.webpackChunkmoja_work||[]).push([[1365,3260],{"./libs/ui/src/lib/_external/mwork-music-player/docs.mdx"(__unused_webpack_module,__webpack_exports__,__webpack_require__){__webpack_require__.r(__webpack_exports__),__webpack_require__.d(__webpack_exports__,{default:()=>MDXContent});__webpack_require__("./node_modules/react/index.js");var react_jsx_runtime__WEBPACK_IMPORTED_MODULE_1__=__webpack_require__("./node_modules/react/jsx-runtime.js"),file_Users_moja_projects_mojawork_mono_node_modules_storybook_addon_docs_dist_mdx_react_shim_js__WEBPACK_IMPORTED_MODULE_2__=__webpack_require__("./node_modules/@mdx-js/react/lib/index.js"),_storybook_addon_docs_blocks__WEBPACK_IMPORTED_MODULE_3__=__webpack_require__("./node_modules/@storybook/addon-docs/dist/blocks.js"),_mwork_music_player_stories__WEBPACK_IMPORTED_MODULE_4__=__webpack_require__("./libs/ui/src/lib/_external/mwork-music-player/mwork-music-player.stories.ts");function _createMdxContent(props){const _components={code:"code",h3:"h3",h4:"h4",hr:"hr",p:"p",pre:"pre",...(0,file_Users_moja_projects_mojawork_mono_node_modules_storybook_addon_docs_dist_mdx_react_shim_js__WEBPACK_IMPORTED_MODULE_2__.R)(),...props.components};return(0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_1__.jsxs)(react_jsx_runtime__WEBPACK_IMPORTED_MODULE_1__.Fragment,{children:[(0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_1__.jsx)(_storybook_addon_docs_blocks__WEBPACK_IMPORTED_MODULE_3__.W8,{of:_mwork_music_player_stories__WEBPACK_IMPORTED_MODULE_4__}),"\n",(0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_1__.jsx)(_components.h3,{id:"external-mwork-music-player",children:"External: Mwork Music Player"}),"\n",(0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_1__.jsxs)(_components.p,{children:[(0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_1__.jsx)(_components.code,{children:"<mwork-music-player>"})," is a minimal music player as a framework-agnostic web component\n(Stencil, from the ",(0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_1__.jsx)(_components.code,{children:"web-components"})," repo, published as ",(0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_1__.jsx)(_components.code,{children:"@mojawork/web-components"}),"). It wraps\na native ",(0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_1__.jsx)(_components.code,{children:"<audio>"})," element with playlist buttons, prev/next/play/pause controls and a\nmetadata section that fetches the active track and displays its ID3 tags — title, album,\nartist and embedded cover, plus the full format and generic tag tables (parsed with\n",(0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_1__.jsx)(_components.code,{children:"music-metadata"}),", the package's only runtime dependency)."]}),"\n",(0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_1__.jsx)(_components.p,{children:"The playlist is fully consumer-provided: the component ships without any built-in URLs.\nThe playlist below is a demo configured in this story."}),"\n",(0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_1__.jsx)(_storybook_addon_docs_blocks__WEBPACK_IMPORTED_MODULE_3__.Hl,{of:_mwork_music_player_stories__WEBPACK_IMPORTED_MODULE_4__.Default}),"\n",(0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_1__.jsx)(_components.hr,{}),"\n",(0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_1__.jsx)(_components.h4,{id:"properties",children:"Properties"}),"\n",(0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_1__.jsxs)("table",{class:"ui",children:[(0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_1__.jsxs)("tr",{children:[(0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_1__.jsx)("th",{style:{width:"14rem"},children:"Property / attribute"}),(0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_1__.jsx)("th",{style:{width:"10rem"},children:"Type"}),(0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_1__.jsx)("th",{style:{width:"8rem"},children:"Default"}),(0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_1__.jsx)("th",{children:"Description"})]}),(0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_1__.jsxs)("tr",{children:[(0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_1__.jsx)("td",{children:(0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_1__.jsx)("code",{children:"tracks"})}),(0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_1__.jsx)("td",{children:(0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_1__.jsx)("code",{children:"string[] | string"})}),(0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_1__.jsx)("td",{children:(0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_1__.jsx)("code",{children:"[]"})}),(0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_1__.jsx)("td",{children:(0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_1__.jsxs)(_components.p,{children:["The playlist. As a property a real string array; as an attribute a JSON array string\n(",(0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_1__.jsx)("code",{children:'\'["a.mp3","b.mp3"]\''}),") or a comma/newline separated list of URLs."]})})]}),(0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_1__.jsxs)("tr",{children:[(0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_1__.jsxs)("td",{children:[(0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_1__.jsx)("code",{children:"show-meta"})," / ",(0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_1__.jsx)("code",{children:"showMeta"})]}),(0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_1__.jsx)("td",{children:(0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_1__.jsx)("code",{children:"boolean"})}),(0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_1__.jsx)("td",{children:(0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_1__.jsx)("code",{children:"true"})}),(0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_1__.jsx)("td",{children:"Show the metadata section (cover and tag tables) below the controls."})]})]}),"\n",(0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_1__.jsx)(_components.h4,{id:"events",children:"Events"}),"\n",(0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_1__.jsxs)("table",{class:"ui",children:[(0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_1__.jsxs)("tr",{children:[(0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_1__.jsx)("th",{style:{width:"14rem"},children:"Event"}),(0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_1__.jsx)("th",{children:"Payload"})]}),(0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_1__.jsxs)("tr",{children:[(0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_1__.jsx)("td",{children:(0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_1__.jsx)("code",{children:"mworkTrackChange"})}),(0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_1__.jsx)("td",{children:(0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_1__.jsxs)(_components.p,{children:[(0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_1__.jsx)("code",{children:"{ index: number, url: string }"})," — fired whenever the active\ntrack changes, including the initial track."]})})]}),(0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_1__.jsxs)("tr",{children:[(0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_1__.jsx)("td",{children:(0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_1__.jsx)("code",{children:"mworkMusicMeta"})}),(0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_1__.jsx)("td",{children:(0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_1__.jsxs)(_components.p,{children:["Essential metadata after a successful parse: ",(0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_1__.jsx)("code",{children:"title"}),", ",(0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_1__.jsx)("code",{children:"track"}),",\n",(0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_1__.jsx)("code",{children:"album"}),", ",(0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_1__.jsx)("code",{children:"artist"}),", ",(0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_1__.jsx)("code",{children:"image"})," (base64 data URL of the\ncover) and ",(0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_1__.jsx)("code",{children:"url"}),"."]})})]})]}),"\n",(0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_1__.jsx)(_components.h4,{id:"methods",children:"Methods"}),"\n",(0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_1__.jsxs)("table",{class:"ui",children:[(0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_1__.jsxs)("tr",{children:[(0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_1__.jsx)("th",{style:{width:"14rem"},children:"Method"}),(0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_1__.jsx)("th",{children:"Effect"})]}),(0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_1__.jsxs)("tr",{children:[(0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_1__.jsxs)("td",{children:[(0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_1__.jsx)("code",{children:"play()"})," / ",(0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_1__.jsx)("code",{children:"pause()"})]}),(0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_1__.jsx)("td",{children:"Start or pause playback of the loaded track."})]}),(0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_1__.jsxs)("tr",{children:[(0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_1__.jsxs)("td",{children:[(0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_1__.jsx)("code",{children:"prev()"})," / ",(0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_1__.jsx)("code",{children:"next()"})]}),(0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_1__.jsx)("td",{children:"Move through the playlist (no-ops at the first/last track)."})]}),(0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_1__.jsxs)("tr",{children:[(0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_1__.jsx)("td",{children:(0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_1__.jsx)("code",{children:"selectTrack(index)"})}),(0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_1__.jsx)("td",{children:"Load and play the track at the given playlist index."})]})]}),"\n",(0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_1__.jsx)(_components.hr,{}),"\n",(0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_1__.jsx)(_components.h4,{id:"variants",children:"Variants"}),"\n",(0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_1__.jsxs)(_components.p,{children:["Without the metadata section (",(0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_1__.jsx)("code",{children:'show-meta="false"'}),"):"]}),"\n",(0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_1__.jsx)(_storybook_addon_docs_blocks__WEBPACK_IMPORTED_MODULE_3__.Hl,{of:_mwork_music_player_stories__WEBPACK_IMPORTED_MODULE_4__.WithoutMeta}),"\n",(0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_1__.jsx)(_components.p,{children:"A single track hides the playlist buttons:"}),"\n",(0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_1__.jsx)(_storybook_addon_docs_blocks__WEBPACK_IMPORTED_MODULE_3__.Hl,{of:_mwork_music_player_stories__WEBPACK_IMPORTED_MODULE_4__.SingleTrack}),"\n",(0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_1__.jsx)(_components.hr,{}),"\n",(0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_1__.jsx)(_components.h4,{id:"theming",children:"Theming"}),"\n",(0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_1__.jsxs)(_components.p,{children:["The player is styled exclusively through its own ",(0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_1__.jsx)("code",{children:"--mwork-player-*"})," CSS custom\nproperties, each with a working default — it needs no surrounding design system and stays\nindependent of the ui library. Apps map their tokens onto them; this story maps the ui\ndesign tokens (theme-aware, so it follows light/dark):"]}),"\n",(0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_1__.jsx)(_components.pre,{children:(0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_1__.jsx)(_components.code,{className:"language-css",children:"mwork-music-player {\n --mwork-player-color: var(--ui-c-default);\n --mwork-player-background: var(--ui-c-background);\n --mwork-player-spacer: var(--ui-spacer);\n --mwork-player-border-width: var(--ui-border-width);\n --mwork-player-border-color: var(--ui-c-fourthly);\n --mwork-player-border-radius: var(--ui-border-radius);\n --mwork-player-accent: var(--ui-c-primary);\n --mwork-player-accent-contrast: var(--ui-c-invert);\n --mwork-player-error-color: var(--ui-c-error);\n}\n"})}),"\n",(0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_1__.jsx)(_storybook_addon_docs_blocks__WEBPACK_IMPORTED_MODULE_3__.Hl,{of:_mwork_music_player_stories__WEBPACK_IMPORTED_MODULE_4__.UiThemed}),"\n",(0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_1__.jsxs)(_components.p,{children:["Additional knobs: ",(0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_1__.jsx)("code",{children:"--mwork-player-font-family"}),",\n",(0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_1__.jsx)("code",{children:"--mwork-player-button-background"})," and ",(0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_1__.jsx)("code",{children:"--mwork-player-cover-size"}),"\n(default ",(0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_1__.jsx)("code",{children:"16rem"}),")."]}),"\n",(0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_1__.jsx)(_components.hr,{}),"\n",(0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_1__.jsx)(_components.h4,{id:"usage-in-an-app",children:"Usage in an app"}),"\n",(0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_1__.jsx)(_components.pre,{children:(0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_1__.jsx)(_components.code,{className:"language-bash",children:"npm i @mojawork/web-components\n"})}),"\n",(0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_1__.jsx)(_components.pre,{children:(0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_1__.jsx)(_components.code,{className:"language-ts",children:"// main.ts — registers all mwork components once\nimport { defineCustomElements } from '@mojawork/web-components/loader';\ndefineCustomElements();\n"})}),"\n",(0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_1__.jsx)(_components.pre,{children:(0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_1__.jsx)(_components.code,{className:"language-html",children:'<mwork-music-player\n tracks=\'["https://moja.work/one.mp3", "https://moja.work/two.mp3"]\'\n></mwork-music-player>\n'})}),"\n",(0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_1__.jsxs)(_components.p,{children:["In Angular templates, bind the playlist as a property (requires\n",(0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_1__.jsx)("code",{children:"CUSTOM_ELEMENTS_SCHEMA"}),"): ",(0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_1__.jsx)("code",{children:'[tracks]="trackUrls"'}),"."]})]})}function MDXContent(props={}){const{wrapper:MDXLayout}={...(0,file_Users_moja_projects_mojawork_mono_node_modules_storybook_addon_docs_dist_mdx_react_shim_js__WEBPACK_IMPORTED_MODULE_2__.R)(),...props.components};return MDXLayout?(0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_1__.jsx)(MDXLayout,{...props,children:(0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_1__.jsx)(_createMdxContent,{...props})}):_createMdxContent(props)}},"./libs/ui/src/lib/_external/mwork-music-player/mwork-music-player.stories.ts"(__unused_webpack_module,__webpack_exports__,__webpack_require__){__webpack_require__.r(__webpack_exports__),__webpack_require__.d(__webpack_exports__,{Default:()=>Default,SingleTrack:()=>SingleTrack,UiThemed:()=>UiThemed,WithoutMeta:()=>WithoutMeta,__namedExportsOrder:()=>__namedExportsOrder,default:()=>__WEBPACK_DEFAULT_EXPORT__});var _angular_core__WEBPACK_IMPORTED_MODULE_0__=__webpack_require__("./node_modules/@angular/core/fesm2022/_debug_node-chunk.mjs"),_storybook_angular__WEBPACK_IMPORTED_MODULE_1__=__webpack_require__("./node_modules/@storybook/angular/dist/index.js"),storybook_actions__WEBPACK_IMPORTED_MODULE_2__=__webpack_require__("storybook/actions");(0,__webpack_require__("../web-components/loader/index.js").u)();const DEMO_TRACKS=["https://moja.work/content/_assets/traks/mojawork-v1.mp3","https://moja.work/content/_assets/traks/mojawork-v2.mp3","https://moja.work/content/_assets/traks/mojawork-v3.mp3"],__WEBPACK_DEFAULT_EXPORT__={title:"External/Mwork Music Player",decorators:[(0,_storybook_angular__WEBPACK_IMPORTED_MODULE_1__.Iz)({schemas:[_angular_core__WEBPACK_IMPORTED_MODULE_0__.CkJ]})],argTypes:{tracks:{control:"object",description:"Playlist as an array of track URLs (property binding); as attribute also a JSON array string or a comma/newline separated list."},showMeta:{control:"boolean",description:"Show the ID3/format metadata section below the controls."},mworkTrackChange:{control:!1,description:"Emitted when the active track changes: { index, url }."},mworkMusicMeta:{control:!1,description:"Emitted after a successful metadata parse: title, track, album, artist, cover image, url."}},args:{tracks:DEMO_TRACKS,showMeta:!0},render:args=>({props:{...args,mworkTrackChange:(0,storybook_actions__WEBPACK_IMPORTED_MODULE_2__.action)("mworkTrackChange"),mworkMusicMeta:(0,storybook_actions__WEBPACK_IMPORTED_MODULE_2__.action)("mworkMusicMeta")},template:'\n <div class="flex justify-center p-4">\n <mwork-music-player\n class="w-full max-w-3xl"\n [tracks]="tracks"\n [showMeta]="showMeta"\n (mworkTrackChange)="mworkTrackChange($event)"\n (mworkMusicMeta)="mworkMusicMeta($event)"\n ></mwork-music-player>\n </div>\n '})},Default={},WithoutMeta={args:{showMeta:!1}},SingleTrack={args:{tracks:[DEMO_TRACKS[0]]}},UiThemed={render:args=>({props:{...args,mworkTrackChange:(0,storybook_actions__WEBPACK_IMPORTED_MODULE_2__.action)("mworkTrackChange"),mworkMusicMeta:(0,storybook_actions__WEBPACK_IMPORTED_MODULE_2__.action)("mworkMusicMeta")},template:'\n <style>\n .ui-themed-music-player {\n --mwork-player-font-family: inherit;\n --mwork-player-color: var(--ui-c-default);\n --mwork-player-background: var(--ui-c-background);\n --mwork-player-spacer: var(--ui-spacer);\n --mwork-player-border-width: var(--ui-border-width);\n --mwork-player-border-color: var(--ui-c-fourthly);\n --mwork-player-border-radius: var(--ui-border-radius);\n --mwork-player-accent: var(--ui-c-primary);\n --mwork-player-accent-contrast: var(--ui-c-invert);\n --mwork-player-error-color: var(--ui-c-error);\n }\n </style>\n <div class="flex justify-center p-4">\n <mwork-music-player\n class="ui-themed-music-player w-full max-w-3xl"\n [tracks]="tracks"\n [showMeta]="showMeta"\n (mworkTrackChange)="mworkTrackChange($event)"\n (mworkMusicMeta)="mworkMusicMeta($event)"\n ></mwork-music-player>\n </div>\n '})},__namedExportsOrder=["Default","WithoutMeta","SingleTrack","UiThemed"];Default.parameters={...Default.parameters,docs:{...Default.parameters?.docs,source:{originalSource:"{}",...Default.parameters?.docs?.source}}},WithoutMeta.parameters={...WithoutMeta.parameters,docs:{...WithoutMeta.parameters?.docs,source:{originalSource:"{\n args: {\n showMeta: false\n }\n}",...WithoutMeta.parameters?.docs?.source}}},SingleTrack.parameters={...SingleTrack.parameters,docs:{...SingleTrack.parameters?.docs,source:{originalSource:"{\n args: {\n tracks: [DEMO_TRACKS[0]]\n }\n}",...SingleTrack.parameters?.docs?.source}}},UiThemed.parameters={...UiThemed.parameters,docs:{...UiThemed.parameters?.docs,source:{originalSource:'{\n render: args => ({\n props: {\n ...args,\n mworkTrackChange: action(\'mworkTrackChange\'),\n mworkMusicMeta: action(\'mworkMusicMeta\')\n },\n template: `\n <style>\n .ui-themed-music-player {\n --mwork-player-font-family: inherit;\n --mwork-player-color: var(--ui-c-default);\n --mwork-player-background: var(--ui-c-background);\n --mwork-player-spacer: var(--ui-spacer);\n --mwork-player-border-width: var(--ui-border-width);\n --mwork-player-border-color: var(--ui-c-fourthly);\n --mwork-player-border-radius: var(--ui-border-radius);\n --mwork-player-accent: var(--ui-c-primary);\n --mwork-player-accent-contrast: var(--ui-c-invert);\n --mwork-player-error-color: var(--ui-c-error);\n }\n </style>\n <div class="flex justify-center p-4">\n <mwork-music-player\n class="ui-themed-music-player w-full max-w-3xl"\n [tracks]="tracks"\n [showMeta]="showMeta"\n (mworkTrackChange)="mworkTrackChange($event)"\n (mworkMusicMeta)="mworkMusicMeta($event)"\n ></mwork-music-player>\n </div>\n `\n })\n}',...UiThemed.parameters?.docs?.source},description:{story:"Maps the ui design tokens onto the component's own `--mwork-player-*`\ncustom properties — the pattern every ui app uses to theme the player.",...UiThemed.parameters?.docs?.description}}}}}]);
@@ -0,0 +1 @@
1
+ "use strict";(self.webpackChunkmoja_work=self.webpackChunkmoja_work||[]).push([[1365],{"./libs/ui/src/lib/_external/mwork-music-player/mwork-music-player.stories.ts"(__unused_webpack_module,__webpack_exports__,__webpack_require__){__webpack_require__.r(__webpack_exports__),__webpack_require__.d(__webpack_exports__,{Default:()=>Default,SingleTrack:()=>SingleTrack,UiThemed:()=>UiThemed,WithoutMeta:()=>WithoutMeta,__namedExportsOrder:()=>__namedExportsOrder,default:()=>__WEBPACK_DEFAULT_EXPORT__});var _angular_core__WEBPACK_IMPORTED_MODULE_0__=__webpack_require__("./node_modules/@angular/core/fesm2022/_debug_node-chunk.mjs"),_storybook_angular__WEBPACK_IMPORTED_MODULE_1__=__webpack_require__("./node_modules/@storybook/angular/dist/index.js"),storybook_actions__WEBPACK_IMPORTED_MODULE_2__=__webpack_require__("storybook/actions");(0,__webpack_require__("../web-components/loader/index.js").u)();const DEMO_TRACKS=["https://moja.work/content/_assets/traks/mojawork-v1.mp3","https://moja.work/content/_assets/traks/mojawork-v2.mp3","https://moja.work/content/_assets/traks/mojawork-v3.mp3"],__WEBPACK_DEFAULT_EXPORT__={title:"External/Mwork Music Player",decorators:[(0,_storybook_angular__WEBPACK_IMPORTED_MODULE_1__.Iz)({schemas:[_angular_core__WEBPACK_IMPORTED_MODULE_0__.CkJ]})],argTypes:{tracks:{control:"object",description:"Playlist as an array of track URLs (property binding); as attribute also a JSON array string or a comma/newline separated list."},showMeta:{control:"boolean",description:"Show the ID3/format metadata section below the controls."},mworkTrackChange:{control:!1,description:"Emitted when the active track changes: { index, url }."},mworkMusicMeta:{control:!1,description:"Emitted after a successful metadata parse: title, track, album, artist, cover image, url."}},args:{tracks:DEMO_TRACKS,showMeta:!0},render:args=>({props:{...args,mworkTrackChange:(0,storybook_actions__WEBPACK_IMPORTED_MODULE_2__.action)("mworkTrackChange"),mworkMusicMeta:(0,storybook_actions__WEBPACK_IMPORTED_MODULE_2__.action)("mworkMusicMeta")},template:'\n <div class="flex justify-center p-4">\n <mwork-music-player\n class="w-full max-w-3xl"\n [tracks]="tracks"\n [showMeta]="showMeta"\n (mworkTrackChange)="mworkTrackChange($event)"\n (mworkMusicMeta)="mworkMusicMeta($event)"\n ></mwork-music-player>\n </div>\n '})},Default={},WithoutMeta={args:{showMeta:!1}},SingleTrack={args:{tracks:[DEMO_TRACKS[0]]}},UiThemed={render:args=>({props:{...args,mworkTrackChange:(0,storybook_actions__WEBPACK_IMPORTED_MODULE_2__.action)("mworkTrackChange"),mworkMusicMeta:(0,storybook_actions__WEBPACK_IMPORTED_MODULE_2__.action)("mworkMusicMeta")},template:'\n <style>\n .ui-themed-music-player {\n --mwork-player-font-family: inherit;\n --mwork-player-color: var(--ui-c-default);\n --mwork-player-background: var(--ui-c-background);\n --mwork-player-spacer: var(--ui-spacer);\n --mwork-player-border-width: var(--ui-border-width);\n --mwork-player-border-color: var(--ui-c-fourthly);\n --mwork-player-border-radius: var(--ui-border-radius);\n --mwork-player-accent: var(--ui-c-primary);\n --mwork-player-accent-contrast: var(--ui-c-invert);\n --mwork-player-error-color: var(--ui-c-error);\n }\n </style>\n <div class="flex justify-center p-4">\n <mwork-music-player\n class="ui-themed-music-player w-full max-w-3xl"\n [tracks]="tracks"\n [showMeta]="showMeta"\n (mworkTrackChange)="mworkTrackChange($event)"\n (mworkMusicMeta)="mworkMusicMeta($event)"\n ></mwork-music-player>\n </div>\n '})},__namedExportsOrder=["Default","WithoutMeta","SingleTrack","UiThemed"];Default.parameters={...Default.parameters,docs:{...Default.parameters?.docs,source:{originalSource:"{}",...Default.parameters?.docs?.source}}},WithoutMeta.parameters={...WithoutMeta.parameters,docs:{...WithoutMeta.parameters?.docs,source:{originalSource:"{\n args: {\n showMeta: false\n }\n}",...WithoutMeta.parameters?.docs?.source}}},SingleTrack.parameters={...SingleTrack.parameters,docs:{...SingleTrack.parameters?.docs,source:{originalSource:"{\n args: {\n tracks: [DEMO_TRACKS[0]]\n }\n}",...SingleTrack.parameters?.docs?.source}}},UiThemed.parameters={...UiThemed.parameters,docs:{...UiThemed.parameters?.docs,source:{originalSource:'{\n render: args => ({\n props: {\n ...args,\n mworkTrackChange: action(\'mworkTrackChange\'),\n mworkMusicMeta: action(\'mworkMusicMeta\')\n },\n template: `\n <style>\n .ui-themed-music-player {\n --mwork-player-font-family: inherit;\n --mwork-player-color: var(--ui-c-default);\n --mwork-player-background: var(--ui-c-background);\n --mwork-player-spacer: var(--ui-spacer);\n --mwork-player-border-width: var(--ui-border-width);\n --mwork-player-border-color: var(--ui-c-fourthly);\n --mwork-player-border-radius: var(--ui-border-radius);\n --mwork-player-accent: var(--ui-c-primary);\n --mwork-player-accent-contrast: var(--ui-c-invert);\n --mwork-player-error-color: var(--ui-c-error);\n }\n </style>\n <div class="flex justify-center p-4">\n <mwork-music-player\n class="ui-themed-music-player w-full max-w-3xl"\n [tracks]="tracks"\n [showMeta]="showMeta"\n (mworkTrackChange)="mworkTrackChange($event)"\n (mworkMusicMeta)="mworkMusicMeta($event)"\n ></mwork-music-player>\n </div>\n `\n })\n}',...UiThemed.parameters?.docs?.source},description:{story:"Maps the ui design tokens onto the component's own `--mwork-player-*`\ncustom properties — the pattern every ui app uses to theme the player.",...UiThemed.parameters?.docs?.description}}}}}]);