@ng-doc/app 16.7.1 → 16.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 (159) hide show
  1. package/components/playground/base-playground.d.ts +12 -5
  2. package/components/playground/playground-demo/playground-demo.component.d.ts +2 -1
  3. package/components/playground/playground-form.d.ts +1 -2
  4. package/components/playground/playground-properties/playground-properties.component.d.ts +3 -1
  5. package/components/playground/playground-property/playground-property.component.d.ts +3 -2
  6. package/components/playground/playground.component.d.ts +11 -7
  7. package/esm2022/components/code/code.component.mjs +5 -7
  8. package/esm2022/components/page/page.component.mjs +5 -28
  9. package/esm2022/components/playground/base-playground.mjs +37 -5
  10. package/esm2022/components/playground/playground-demo/playground-demo.component.mjs +14 -12
  11. package/esm2022/components/playground/playground-form.mjs +1 -1
  12. package/esm2022/components/playground/playground-properties/playground-properties.component.mjs +12 -5
  13. package/esm2022/components/playground/playground-property/playground-property.component.mjs +12 -12
  14. package/esm2022/components/playground/playground.component.mjs +34 -14
  15. package/esm2022/interfaces/index.mjs +2 -1
  16. package/esm2022/interfaces/page-processor.mjs +2 -0
  17. package/esm2022/interfaces/processor-options.mjs +1 -1
  18. package/esm2022/interfaces/type-control.mjs +1 -1
  19. package/esm2022/modules/root/ng-doc.module.mjs +3 -1
  20. package/esm2022/processors/default-processors.mjs +18 -0
  21. package/esm2022/processors/index.mjs +4 -11
  22. package/esm2022/processors/{code-processor → page-processor}/index.mjs +2 -2
  23. package/esm2022/processors/{icon-processor/ng-doc-app-processors-icon-processor.mjs → page-processor/ng-doc-app-processors-page-processor.mjs} +1 -1
  24. package/esm2022/processors/page-processor/page-processor.directive.mjs +52 -0
  25. package/esm2022/processors/processors/blockquote.processor.mjs +12 -0
  26. package/esm2022/processors/processors/code.processor.mjs +15 -0
  27. package/esm2022/processors/processors/demo-pane.processor.mjs +12 -0
  28. package/esm2022/processors/processors/demo.processor.mjs +12 -0
  29. package/esm2022/processors/processors/icon.processor.mjs +12 -0
  30. package/esm2022/processors/processors/index.mjs +10 -0
  31. package/esm2022/processors/processors/link.processor.mjs +13 -0
  32. package/esm2022/processors/processors/ng-doc-app-processors-processors.mjs +5 -0
  33. package/esm2022/processors/processors/playground.processor.mjs +19 -0
  34. package/esm2022/processors/processors/tabs.processor.mjs +25 -0
  35. package/esm2022/processors/processors/tooltip.processor.mjs +58 -0
  36. package/esm2022/tokens/index.mjs +2 -1
  37. package/esm2022/tokens/page-processor.mjs +17 -0
  38. package/esm2022/type-controls/boolean-control/boolean-control.component.mjs +7 -1
  39. package/esm2022/type-controls/number-control/number-control.component.mjs +8 -10
  40. package/esm2022/type-controls/string-control/string-control.component.mjs +8 -10
  41. package/esm2022/type-controls/type-alias-control/type-alias-control.component.mjs +8 -10
  42. package/fesm2022/ng-doc-app-components-code.mjs +4 -6
  43. package/fesm2022/ng-doc-app-components-code.mjs.map +1 -1
  44. package/fesm2022/ng-doc-app-components-page.mjs +4 -27
  45. package/fesm2022/ng-doc-app-components-page.mjs.map +1 -1
  46. package/fesm2022/ng-doc-app-components-playground.mjs +121 -64
  47. package/fesm2022/ng-doc-app-components-playground.mjs.map +1 -1
  48. package/fesm2022/ng-doc-app-modules-root.mjs +2 -0
  49. package/fesm2022/ng-doc-app-modules-root.mjs.map +1 -1
  50. package/fesm2022/ng-doc-app-processors-page-processor.mjs +58 -0
  51. package/fesm2022/ng-doc-app-processors-page-processor.mjs.map +1 -0
  52. package/fesm2022/ng-doc-app-processors-processors.mjs +183 -0
  53. package/fesm2022/ng-doc-app-processors-processors.mjs.map +1 -0
  54. package/fesm2022/ng-doc-app-processors.mjs +22 -10
  55. package/fesm2022/ng-doc-app-processors.mjs.map +1 -1
  56. package/fesm2022/ng-doc-app-tokens.mjs +17 -1
  57. package/fesm2022/ng-doc-app-tokens.mjs.map +1 -1
  58. package/fesm2022/ng-doc-app-type-controls-boolean-control.mjs +6 -0
  59. package/fesm2022/ng-doc-app-type-controls-boolean-control.mjs.map +1 -1
  60. package/fesm2022/ng-doc-app-type-controls-number-control.mjs +7 -9
  61. package/fesm2022/ng-doc-app-type-controls-number-control.mjs.map +1 -1
  62. package/fesm2022/ng-doc-app-type-controls-string-control.mjs +7 -9
  63. package/fesm2022/ng-doc-app-type-controls-string-control.mjs.map +1 -1
  64. package/fesm2022/ng-doc-app-type-controls-type-alias-control.mjs +7 -9
  65. package/fesm2022/ng-doc-app-type-controls-type-alias-control.mjs.map +1 -1
  66. package/interfaces/index.d.ts +1 -0
  67. package/interfaces/page-processor.d.ts +28 -0
  68. package/interfaces/processor-options.d.ts +2 -3
  69. package/interfaces/type-control.d.ts +2 -2
  70. package/package.json +14 -62
  71. package/processors/default-processors.d.ts +2 -0
  72. package/processors/index.d.ts +3 -10
  73. package/processors/page-processor/index.d.ts +1 -0
  74. package/processors/page-processor/page-processor.directive.d.ts +19 -0
  75. package/processors/processors/blockquote.processor.d.ts +3 -0
  76. package/processors/processors/code.processor.d.ts +3 -0
  77. package/processors/processors/demo-pane.processor.d.ts +3 -0
  78. package/processors/processors/demo.processor.d.ts +3 -0
  79. package/processors/processors/icon.processor.d.ts +3 -0
  80. package/processors/processors/index.d.ts +9 -0
  81. package/processors/processors/link.processor.d.ts +3 -0
  82. package/processors/processors/playground.processor.d.ts +3 -0
  83. package/processors/processors/tabs.processor.d.ts +3 -0
  84. package/processors/{tooltip-processor/tooltip-wrapper.component.d.ts → processors/tooltip.processor.d.ts} +4 -1
  85. package/tokens/index.d.ts +1 -0
  86. package/tokens/page-processor.d.ts +11 -0
  87. package/type-controls/boolean-control/boolean-control.component.d.ts +4 -1
  88. package/type-controls/number-control/number-control.component.d.ts +3 -4
  89. package/type-controls/string-control/string-control.component.d.ts +2 -3
  90. package/type-controls/type-alias-control/type-alias-control.component.d.ts +3 -4
  91. package/esm2022/processors/blockquote-processor/blockquote-processor.directive.mjs +0 -30
  92. package/esm2022/processors/blockquote-processor/index.mjs +0 -2
  93. package/esm2022/processors/blockquote-processor/ng-doc-app-processors-blockquote-processor.mjs +0 -5
  94. package/esm2022/processors/code-processor/code-processor.directive.mjs +0 -35
  95. package/esm2022/processors/code-processor/ng-doc-app-processors-code-processor.mjs +0 -5
  96. package/esm2022/processors/demo-pane-processor/demo-pane-processor.directive.mjs +0 -38
  97. package/esm2022/processors/demo-pane-processor/index.mjs +0 -2
  98. package/esm2022/processors/demo-pane-processor/ng-doc-app-processors-demo-pane-processor.mjs +0 -5
  99. package/esm2022/processors/demo-processor/demo-processor.directive.mjs +0 -38
  100. package/esm2022/processors/demo-processor/index.mjs +0 -2
  101. package/esm2022/processors/demo-processor/ng-doc-app-processors-demo-processor.mjs +0 -5
  102. package/esm2022/processors/html-processor/html-processor.directive.mjs +0 -44
  103. package/esm2022/processors/html-processor/index.mjs +0 -2
  104. package/esm2022/processors/html-processor/ng-doc-app-processors-html-processor.mjs +0 -5
  105. package/esm2022/processors/icon-processor/icon-processor.directive.mjs +0 -30
  106. package/esm2022/processors/icon-processor/index.mjs +0 -2
  107. package/esm2022/processors/link-processor/index.mjs +0 -2
  108. package/esm2022/processors/link-processor/link-processor.directive.mjs +0 -31
  109. package/esm2022/processors/link-processor/ng-doc-app-processors-link-processor.mjs +0 -5
  110. package/esm2022/processors/playground-processor/index.mjs +0 -2
  111. package/esm2022/processors/playground-processor/ng-doc-app-processors-playground-processor.mjs +0 -5
  112. package/esm2022/processors/playground-processor/playground-processor.directive.mjs +0 -36
  113. package/esm2022/processors/tabs-processor/index.mjs +0 -2
  114. package/esm2022/processors/tabs-processor/ng-doc-app-processors-tabs-processor.mjs +0 -5
  115. package/esm2022/processors/tabs-processor/tabs-processor.directive.mjs +0 -44
  116. package/esm2022/processors/tooltip-processor/index.mjs +0 -3
  117. package/esm2022/processors/tooltip-processor/ng-doc-app-processors-tooltip-processor.mjs +0 -5
  118. package/esm2022/processors/tooltip-processor/tooltip-processor.directive.mjs +0 -30
  119. package/esm2022/processors/tooltip-processor/tooltip-wrapper.component.mjs +0 -49
  120. package/fesm2022/ng-doc-app-processors-blockquote-processor.mjs +0 -36
  121. package/fesm2022/ng-doc-app-processors-blockquote-processor.mjs.map +0 -1
  122. package/fesm2022/ng-doc-app-processors-code-processor.mjs +0 -41
  123. package/fesm2022/ng-doc-app-processors-code-processor.mjs.map +0 -1
  124. package/fesm2022/ng-doc-app-processors-demo-pane-processor.mjs +0 -44
  125. package/fesm2022/ng-doc-app-processors-demo-pane-processor.mjs.map +0 -1
  126. package/fesm2022/ng-doc-app-processors-demo-processor.mjs +0 -44
  127. package/fesm2022/ng-doc-app-processors-demo-processor.mjs.map +0 -1
  128. package/fesm2022/ng-doc-app-processors-html-processor.mjs +0 -50
  129. package/fesm2022/ng-doc-app-processors-html-processor.mjs.map +0 -1
  130. package/fesm2022/ng-doc-app-processors-icon-processor.mjs +0 -36
  131. package/fesm2022/ng-doc-app-processors-icon-processor.mjs.map +0 -1
  132. package/fesm2022/ng-doc-app-processors-link-processor.mjs +0 -37
  133. package/fesm2022/ng-doc-app-processors-link-processor.mjs.map +0 -1
  134. package/fesm2022/ng-doc-app-processors-playground-processor.mjs +0 -42
  135. package/fesm2022/ng-doc-app-processors-playground-processor.mjs.map +0 -1
  136. package/fesm2022/ng-doc-app-processors-tabs-processor.mjs +0 -50
  137. package/fesm2022/ng-doc-app-processors-tabs-processor.mjs.map +0 -1
  138. package/fesm2022/ng-doc-app-processors-tooltip-processor.mjs +0 -81
  139. package/fesm2022/ng-doc-app-processors-tooltip-processor.mjs.map +0 -1
  140. package/processors/blockquote-processor/blockquote-processor.directive.d.ts +0 -13
  141. package/processors/blockquote-processor/index.d.ts +0 -1
  142. package/processors/code-processor/code-processor.directive.d.ts +0 -14
  143. package/processors/code-processor/index.d.ts +0 -1
  144. package/processors/demo-pane-processor/demo-pane-processor.directive.d.ts +0 -14
  145. package/processors/demo-pane-processor/index.d.ts +0 -1
  146. package/processors/demo-processor/demo-processor.directive.d.ts +0 -14
  147. package/processors/demo-processor/index.d.ts +0 -1
  148. package/processors/html-processor/html-processor.directive.d.ts +0 -20
  149. package/processors/html-processor/index.d.ts +0 -1
  150. package/processors/icon-processor/icon-processor.directive.d.ts +0 -13
  151. package/processors/icon-processor/index.d.ts +0 -1
  152. package/processors/link-processor/index.d.ts +0 -1
  153. package/processors/link-processor/link-processor.directive.d.ts +0 -13
  154. package/processors/playground-processor/index.d.ts +0 -1
  155. package/processors/playground-processor/playground-processor.directive.d.ts +0 -13
  156. package/processors/tabs-processor/index.d.ts +0 -1
  157. package/processors/tabs-processor/tabs-processor.directive.d.ts +0 -15
  158. package/processors/tooltip-processor/index.d.ts +0 -2
  159. package/processors/tooltip-processor/tooltip-processor.directive.d.ts +0 -13
@@ -8,7 +8,7 @@ import { NgDocBreadcrumbComponent } from '@ng-doc/app/components/breadcrumb';
8
8
  import { NgDocTocComponent } from '@ng-doc/app/components/toc';
9
9
  import { provideTypeControl } from '@ng-doc/app/helpers';
10
10
  import { NgDocSanitizeHtmlPipe } from '@ng-doc/app/pipes/sanitize-html';
11
- import { NgDocBlockquoteProcessorDirective, NgDocIconProcessorDirective, NgDocTooltipProcessorDirective, NgDocLinkProcessorDirective, NgDocCodeProcessorDirective, NgDocDemoProcessorDirective, NgDocDemoPaneProcessorDirective, NgDocPlaygroundProcessorDirective, NgDocTabsProcessorDirective } from '@ng-doc/app/processors';
11
+ import { NgDocPageProcessorDirective } from '@ng-doc/app/processors';
12
12
  import { NG_DOC_CONTEXT } from '@ng-doc/app/tokens';
13
13
  import { NgDocTypeAliasControlComponent, NgDocStringControlComponent, NgDocNumberControlComponent, NgDocBooleanControlComponent } from '@ng-doc/app/type-controls';
14
14
  import { NgDocButtonIconComponent, NgDocTooltipDirective, NgDocIconComponent, NgDocTextComponent, NgDocTextLeftDirective, NgDocTextRightDirective, NgDocMediaQueryDirective } from '@ng-doc/ui-kit';
@@ -37,15 +37,7 @@ class NgDocPageComponent {
37
37
  provideTypeControl('string', NgDocStringControlComponent, { order: 20 }),
38
38
  provideTypeControl('number', NgDocNumberControlComponent, { order: 30 }),
39
39
  provideTypeControl('boolean', NgDocBooleanControlComponent, { hideLabel: true, order: 40 }),
40
- ], ngImport: i0, template: "<article>\n\t<ng-doc-breadcrumb *ngIf=\"rootPage.pageType === 'guide'\"></ng-doc-breadcrumb>\n\t<div class=\"ng-doc-page-controls\">\n\t\t<a\n\t\t\tng-doc-button-icon\n\t\t\t*ngIf=\"rootPage.editSourceFileUrl\"\n\t\t\t[href]=\"rootPage.editSourceFileUrl\"\n\t\t\ttarget=\"_blank\"\n\t\t\tngDocTooltip=\"Suggest Edits\"\n\t\t>\n\t\t\t<ng-doc-icon icon=\"edit-2\"></ng-doc-icon>\n\t\t</a>\n\t\t<a\n\t\t\tng-doc-button-icon\n\t\t\t*ngIf=\"rootPage.viewSourceFileUrl\"\n\t\t\t[href]=\"rootPage.viewSourceFileUrl\"\n\t\t\ttarget=\"_blank\"\n\t\t\tngDocTooltip=\"View Source\"\n\t\t>\n\t\t\t<ng-doc-icon icon=\"code\"></ng-doc-icon>\n\t\t</a>\n\t</div>\n\n\t<div\n\t\tclass=\"ng-doc-page-wrapper\"\n\t\t[innerHTML]=\"rootPage.pageContent | ngDocSanitizeHtml\"\n\t\tngDocBlockquoteProcessor\n\t\tngDocLinkProcessor\n\t\tngDocCodeProcessor\n\t\tngDocIconProcessor\n\t\tngDocTooltipProcessor\n\t\tngDocDemoProcessor\n\t\tngDocDemoPaneProcessor\n\t\tngDocPlaygroundProcessor\n\t\tngDocTabsProcessor\n\t\t#pageContainer\n\t></div>\n\n\t<div class=\"ng-doc-navigation-controls\" *ngIf=\"rootPage.pageType === 'guide'\">\n\t\t<a class=\"ng-doc-prev-page\" *ngIf=\"prevPage\" [routerLink]=\"prevPage.route\">\n\t\t\t<div class=\"ng-doc-navigation-page-label\" ng-doc-text size=\"small\">\n\t\t\t\t<ng-doc-icon icon=\"arrow-left\" ngDocTextLeft></ng-doc-icon>\n\t\t\t\tPrevious\n\t\t\t</div>\n\t\t\t<div class=\"ng-doc-navigation-page-title\" ng-doc-text>{{ prevPage.title }}</div>\n\t\t</a>\n\t\t<a class=\"ng-doc-next-page\" *ngIf=\"nextPage\" [routerLink]=\"nextPage.route\">\n\t\t\t<div class=\"ng-doc-navigation-page-label\" ng-doc-text size=\"small\">\n\t\t\t\tNext\n\t\t\t\t<ng-doc-icon icon=\"arrow-right\" ngDocTextRight></ng-doc-icon>\n\t\t\t</div>\n\t\t\t<div class=\"ng-doc-navigation-page-title\" ng-doc-text>{{ nextPage.title }}</div>\n\t\t</a>\n\t</div>\n</article>\n\n<ng-template\n\t[ngDocMediaQuery]=\"[mediaQuery.breakpoints.Large, mediaQuery.breakpoints.XLarge]\"\n\t#mediaQuery=\"ngDocMediaQuery\"\n>\n\t<ng-doc-toc [pageContainer]=\"pageContainer\"></ng-doc-toc>\n</ng-template>\n", styles: [":host{display:flex}:host article{position:relative;width:var(--ng-doc-article-width, 100%);margin-left:auto;margin-right:auto;overflow:hidden}:host article .ng-doc-page-controls{position:absolute;display:flex;grid-gap:var(--ng-doc-base-gutter);top:0;right:0}:host ng-doc-toc{--ng-doc-toc-margin: calc(var(--ng-doc-base-gutter) * 3);flex-shrink:0}@media screen and (max-width: 1200px){:host ng-doc-toc{display:none}}:host .ng-doc-navigation-controls{display:flex;margin-top:calc(var(--ng-doc-base-gutter) * 12);border-top:1px solid var(--ng-doc-base-2);padding-top:calc(var(--ng-doc-base-gutter) * 2)}:host .ng-doc-navigation-controls a{display:flex;flex-direction:column;text-decoration:unset;transition:var(--ng-doc-transition);--ng-doc-button-hover-background: var(--ng-doc-base-1);--ng-doc-button-active-background: var(--ng-doc-base-2);--ng-doc-text: var(--ng-doc-base-10);--ng-doc-icon-color: var(--ng-doc-text)}:host .ng-doc-navigation-controls a:hover{opacity:.6}:host .ng-doc-navigation-controls a.ng-doc-next-page{margin-left:auto}:host .ng-doc-navigation-controls a.ng-doc-prev-page{align-items:flex-start}:host .ng-doc-navigation-controls a.ng-doc-next-page{align-items:flex-end}:host .ng-doc-navigation-controls a .ng-doc-navigation-page-title{--ng-doc-font-weight: 600;--ng-doc-text: var(--ng-doc-link-color)}\n"], dependencies: [{ kind: "directive", type: NgIf, selector: "[ngIf]", inputs: ["ngIf", "ngIfThen", "ngIfElse"] }, { kind: "component", type: NgDocBreadcrumbComponent, selector: "ng-doc-breadcrumb" }, { kind: "component", type: NgDocButtonIconComponent, selector: "button[ng-doc-button-icon], a[ng-doc-button-icon]", inputs: ["size", "rounded"] }, { kind: "directive", type: NgDocTooltipDirective, selector: "[ngDocTooltip]", inputs: ["ngDocTooltip", "delay", "displayOrigin", "pointerOrigin", "positions", "canOpen", "panelClass", "minHeight", "maxHeight", "height", "minWidth", "maxWidth", "width"], outputs: ["beforeOpen", "afterOpen", "beforeClose", "afterClose"], exportAs: ["ngDocTooltip"] }, { kind: "component", type: NgDocIconComponent, selector: "ng-doc-icon", inputs: ["icon", "size"] }, { kind: "directive", type: NgDocBlockquoteProcessorDirective, selector: "[ngDocBlockquoteProcessor]" }, { kind: "directive", type: NgDocIconProcessorDirective, selector: "[ngDocIconProcessor]" }, { kind: "directive", type:
41
- /**
42
- * The order of the directives is important.
43
- * The higher the directive is in the list, the later it will be run.
44
- *
45
- * So here we want to render demos first, after that we want to render links
46
- * and bind tooltips to them.
47
- */
48
- NgDocTooltipProcessorDirective, selector: "[ngDocTooltipProcessor]" }, { kind: "directive", type: NgDocLinkProcessorDirective, selector: "[ngDocLinkProcessor]" }, { kind: "directive", type: NgDocCodeProcessorDirective, selector: "[ngDocCodeProcessor]" }, { kind: "directive", type: NgDocDemoProcessorDirective, selector: "[ngDocDemoProcessor]" }, { kind: "directive", type: NgDocDemoPaneProcessorDirective, selector: "[ngDocDemoPaneProcessor]" }, { kind: "directive", type: NgDocPlaygroundProcessorDirective, selector: "[ngDocPlaygroundProcessor]" }, { kind: "directive", type: NgDocTabsProcessorDirective, selector: "[ngDocTabsProcessor]" }, { kind: "directive", type: RouterLink, selector: "[routerLink]", inputs: ["target", "queryParams", "fragment", "queryParamsHandling", "state", "relativeTo", "preserveFragment", "skipLocationChange", "replaceUrl", "routerLink"] }, { kind: "component", type: NgDocTextComponent, selector: "[ng-doc-text]", inputs: ["size", "color", "align", "absoluteContent"] }, { kind: "directive", type: NgDocTextLeftDirective, selector: "[ngDocTextLeft]" }, { kind: "directive", type: NgDocTextRightDirective, selector: "[ngDocTextRight]" }, { kind: "directive", type: NgDocMediaQueryDirective, selector: "[ngDocMediaQuery]", inputs: ["ngDocMediaQuery"], exportAs: ["ngDocMediaQuery"] }, { kind: "component", type: NgDocTocComponent, selector: "ng-doc-toc", inputs: ["pageContainer"] }, { kind: "pipe", type: NgDocSanitizeHtmlPipe, name: "ngDocSanitizeHtml" }], changeDetection: i0.ChangeDetectionStrategy.OnPush }); }
40
+ ], ngImport: i0, template: "<article>\n\t<ng-doc-breadcrumb *ngIf=\"rootPage.pageType === 'guide'\"></ng-doc-breadcrumb>\n\t<div class=\"ng-doc-page-controls\">\n\t\t<a\n\t\t\tng-doc-button-icon\n\t\t\t*ngIf=\"rootPage.editSourceFileUrl\"\n\t\t\t[href]=\"rootPage.editSourceFileUrl\"\n\t\t\ttarget=\"_blank\"\n\t\t\tngDocTooltip=\"Suggest Edits\"\n\t\t>\n\t\t\t<ng-doc-icon icon=\"edit-2\"></ng-doc-icon>\n\t\t</a>\n\t\t<a\n\t\t\tng-doc-button-icon\n\t\t\t*ngIf=\"rootPage.viewSourceFileUrl\"\n\t\t\t[href]=\"rootPage.viewSourceFileUrl\"\n\t\t\ttarget=\"_blank\"\n\t\t\tngDocTooltip=\"View Source\"\n\t\t>\n\t\t\t<ng-doc-icon icon=\"code\"></ng-doc-icon>\n\t\t</a>\n\t</div>\n\n\t<div\n\t\tclass=\"ng-doc-page-wrapper\"\n\t\t[innerHTML]=\"rootPage.pageContent | ngDocSanitizeHtml\"\n\t\tngDocPageProcessor\n\t\t#pageContainer\n\t></div>\n\n\t<div class=\"ng-doc-navigation-controls\" *ngIf=\"rootPage.pageType === 'guide'\">\n\t\t<a class=\"ng-doc-prev-page\" *ngIf=\"prevPage\" [routerLink]=\"prevPage.route\">\n\t\t\t<div class=\"ng-doc-navigation-page-label\" ng-doc-text size=\"small\">\n\t\t\t\t<ng-doc-icon icon=\"arrow-left\" ngDocTextLeft></ng-doc-icon>\n\t\t\t\tPrevious\n\t\t\t</div>\n\t\t\t<div class=\"ng-doc-navigation-page-title\" ng-doc-text>{{ prevPage.title }}</div>\n\t\t</a>\n\t\t<a class=\"ng-doc-next-page\" *ngIf=\"nextPage\" [routerLink]=\"nextPage.route\">\n\t\t\t<div class=\"ng-doc-navigation-page-label\" ng-doc-text size=\"small\">\n\t\t\t\tNext\n\t\t\t\t<ng-doc-icon icon=\"arrow-right\" ngDocTextRight></ng-doc-icon>\n\t\t\t</div>\n\t\t\t<div class=\"ng-doc-navigation-page-title\" ng-doc-text>{{ nextPage.title }}</div>\n\t\t</a>\n\t</div>\n</article>\n\n<ng-template\n\t[ngDocMediaQuery]=\"[mediaQuery.breakpoints.Large, mediaQuery.breakpoints.XLarge]\"\n\t#mediaQuery=\"ngDocMediaQuery\"\n>\n\t<ng-doc-toc [pageContainer]=\"pageContainer\"></ng-doc-toc>\n</ng-template>\n", styles: [":host{display:flex}:host article{position:relative;width:var(--ng-doc-article-width, 100%);margin-left:auto;margin-right:auto;overflow:hidden}:host article .ng-doc-page-controls{position:absolute;display:flex;grid-gap:var(--ng-doc-base-gutter);top:0;right:0}:host ng-doc-toc{--ng-doc-toc-margin: calc(var(--ng-doc-base-gutter) * 3);flex-shrink:0}@media screen and (max-width: 1200px){:host ng-doc-toc{display:none}}:host .ng-doc-navigation-controls{display:flex;margin-top:calc(var(--ng-doc-base-gutter) * 12);border-top:1px solid var(--ng-doc-base-2);padding-top:calc(var(--ng-doc-base-gutter) * 2)}:host .ng-doc-navigation-controls a{display:flex;flex-direction:column;text-decoration:unset;transition:var(--ng-doc-transition);--ng-doc-button-hover-background: var(--ng-doc-base-1);--ng-doc-button-active-background: var(--ng-doc-base-2);--ng-doc-text: var(--ng-doc-base-10);--ng-doc-icon-color: var(--ng-doc-text)}:host .ng-doc-navigation-controls a:hover{opacity:.6}:host .ng-doc-navigation-controls a.ng-doc-next-page{margin-left:auto}:host .ng-doc-navigation-controls a.ng-doc-prev-page{align-items:flex-start}:host .ng-doc-navigation-controls a.ng-doc-next-page{align-items:flex-end}:host .ng-doc-navigation-controls a .ng-doc-navigation-page-title{--ng-doc-font-weight: 600;--ng-doc-text: var(--ng-doc-link-color)}\n"], dependencies: [{ kind: "directive", type: NgIf, selector: "[ngIf]", inputs: ["ngIf", "ngIfThen", "ngIfElse"] }, { kind: "component", type: NgDocBreadcrumbComponent, selector: "ng-doc-breadcrumb" }, { kind: "component", type: NgDocButtonIconComponent, selector: "button[ng-doc-button-icon], a[ng-doc-button-icon]", inputs: ["size", "rounded"] }, { kind: "directive", type: NgDocTooltipDirective, selector: "[ngDocTooltip]", inputs: ["ngDocTooltip", "delay", "displayOrigin", "pointerOrigin", "positions", "canOpen", "panelClass", "minHeight", "maxHeight", "height", "minWidth", "maxWidth", "width"], outputs: ["beforeOpen", "afterOpen", "beforeClose", "afterClose"], exportAs: ["ngDocTooltip"] }, { kind: "component", type: NgDocIconComponent, selector: "ng-doc-icon", inputs: ["icon", "size"] }, { kind: "directive", type: RouterLink, selector: "[routerLink]", inputs: ["target", "queryParams", "fragment", "queryParamsHandling", "state", "relativeTo", "preserveFragment", "skipLocationChange", "replaceUrl", "routerLink"] }, { kind: "component", type: NgDocTextComponent, selector: "[ng-doc-text]", inputs: ["size", "color", "align", "absoluteContent"] }, { kind: "directive", type: NgDocTextLeftDirective, selector: "[ngDocTextLeft]" }, { kind: "directive", type: NgDocTextRightDirective, selector: "[ngDocTextRight]" }, { kind: "directive", type: NgDocMediaQueryDirective, selector: "[ngDocMediaQuery]", inputs: ["ngDocMediaQuery"], exportAs: ["ngDocMediaQuery"] }, { kind: "component", type: NgDocTocComponent, selector: "ng-doc-toc", inputs: ["pageContainer"] }, { kind: "pipe", type: NgDocSanitizeHtmlPipe, name: "ngDocSanitizeHtml" }, { kind: "directive", type: NgDocPageProcessorDirective, selector: "[ngDocPageProcessor]" }], changeDetection: i0.ChangeDetectionStrategy.OnPush }); }
49
41
  }
50
42
  i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "16.0.0", ngImport: i0, type: NgDocPageComponent, decorators: [{
51
43
  type: Component,
@@ -55,22 +47,6 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "16.0.0", ngImpor
55
47
  NgDocButtonIconComponent,
56
48
  NgDocTooltipDirective,
57
49
  NgDocIconComponent,
58
- NgDocBlockquoteProcessorDirective,
59
- NgDocIconProcessorDirective,
60
- /**
61
- * The order of the directives is important.
62
- * The higher the directive is in the list, the later it will be run.
63
- *
64
- * So here we want to render demos first, after that we want to render links
65
- * and bind tooltips to them.
66
- */
67
- NgDocTooltipProcessorDirective,
68
- NgDocLinkProcessorDirective,
69
- NgDocCodeProcessorDirective,
70
- NgDocDemoProcessorDirective,
71
- NgDocDemoPaneProcessorDirective,
72
- NgDocPlaygroundProcessorDirective,
73
- NgDocTabsProcessorDirective,
74
50
  RouterLink,
75
51
  NgDocTextComponent,
76
52
  NgDocTextLeftDirective,
@@ -78,12 +54,13 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "16.0.0", ngImpor
78
54
  NgDocMediaQueryDirective,
79
55
  NgDocTocComponent,
80
56
  NgDocSanitizeHtmlPipe,
57
+ NgDocPageProcessorDirective,
81
58
  ], providers: [
82
59
  provideTypeControl('NgDocTypeAlias', NgDocTypeAliasControlComponent, { order: 10 }),
83
60
  provideTypeControl('string', NgDocStringControlComponent, { order: 20 }),
84
61
  provideTypeControl('number', NgDocNumberControlComponent, { order: 30 }),
85
62
  provideTypeControl('boolean', NgDocBooleanControlComponent, { hideLabel: true, order: 40 }),
86
- ], template: "<article>\n\t<ng-doc-breadcrumb *ngIf=\"rootPage.pageType === 'guide'\"></ng-doc-breadcrumb>\n\t<div class=\"ng-doc-page-controls\">\n\t\t<a\n\t\t\tng-doc-button-icon\n\t\t\t*ngIf=\"rootPage.editSourceFileUrl\"\n\t\t\t[href]=\"rootPage.editSourceFileUrl\"\n\t\t\ttarget=\"_blank\"\n\t\t\tngDocTooltip=\"Suggest Edits\"\n\t\t>\n\t\t\t<ng-doc-icon icon=\"edit-2\"></ng-doc-icon>\n\t\t</a>\n\t\t<a\n\t\t\tng-doc-button-icon\n\t\t\t*ngIf=\"rootPage.viewSourceFileUrl\"\n\t\t\t[href]=\"rootPage.viewSourceFileUrl\"\n\t\t\ttarget=\"_blank\"\n\t\t\tngDocTooltip=\"View Source\"\n\t\t>\n\t\t\t<ng-doc-icon icon=\"code\"></ng-doc-icon>\n\t\t</a>\n\t</div>\n\n\t<div\n\t\tclass=\"ng-doc-page-wrapper\"\n\t\t[innerHTML]=\"rootPage.pageContent | ngDocSanitizeHtml\"\n\t\tngDocBlockquoteProcessor\n\t\tngDocLinkProcessor\n\t\tngDocCodeProcessor\n\t\tngDocIconProcessor\n\t\tngDocTooltipProcessor\n\t\tngDocDemoProcessor\n\t\tngDocDemoPaneProcessor\n\t\tngDocPlaygroundProcessor\n\t\tngDocTabsProcessor\n\t\t#pageContainer\n\t></div>\n\n\t<div class=\"ng-doc-navigation-controls\" *ngIf=\"rootPage.pageType === 'guide'\">\n\t\t<a class=\"ng-doc-prev-page\" *ngIf=\"prevPage\" [routerLink]=\"prevPage.route\">\n\t\t\t<div class=\"ng-doc-navigation-page-label\" ng-doc-text size=\"small\">\n\t\t\t\t<ng-doc-icon icon=\"arrow-left\" ngDocTextLeft></ng-doc-icon>\n\t\t\t\tPrevious\n\t\t\t</div>\n\t\t\t<div class=\"ng-doc-navigation-page-title\" ng-doc-text>{{ prevPage.title }}</div>\n\t\t</a>\n\t\t<a class=\"ng-doc-next-page\" *ngIf=\"nextPage\" [routerLink]=\"nextPage.route\">\n\t\t\t<div class=\"ng-doc-navigation-page-label\" ng-doc-text size=\"small\">\n\t\t\t\tNext\n\t\t\t\t<ng-doc-icon icon=\"arrow-right\" ngDocTextRight></ng-doc-icon>\n\t\t\t</div>\n\t\t\t<div class=\"ng-doc-navigation-page-title\" ng-doc-text>{{ nextPage.title }}</div>\n\t\t</a>\n\t</div>\n</article>\n\n<ng-template\n\t[ngDocMediaQuery]=\"[mediaQuery.breakpoints.Large, mediaQuery.breakpoints.XLarge]\"\n\t#mediaQuery=\"ngDocMediaQuery\"\n>\n\t<ng-doc-toc [pageContainer]=\"pageContainer\"></ng-doc-toc>\n</ng-template>\n", styles: [":host{display:flex}:host article{position:relative;width:var(--ng-doc-article-width, 100%);margin-left:auto;margin-right:auto;overflow:hidden}:host article .ng-doc-page-controls{position:absolute;display:flex;grid-gap:var(--ng-doc-base-gutter);top:0;right:0}:host ng-doc-toc{--ng-doc-toc-margin: calc(var(--ng-doc-base-gutter) * 3);flex-shrink:0}@media screen and (max-width: 1200px){:host ng-doc-toc{display:none}}:host .ng-doc-navigation-controls{display:flex;margin-top:calc(var(--ng-doc-base-gutter) * 12);border-top:1px solid var(--ng-doc-base-2);padding-top:calc(var(--ng-doc-base-gutter) * 2)}:host .ng-doc-navigation-controls a{display:flex;flex-direction:column;text-decoration:unset;transition:var(--ng-doc-transition);--ng-doc-button-hover-background: var(--ng-doc-base-1);--ng-doc-button-active-background: var(--ng-doc-base-2);--ng-doc-text: var(--ng-doc-base-10);--ng-doc-icon-color: var(--ng-doc-text)}:host .ng-doc-navigation-controls a:hover{opacity:.6}:host .ng-doc-navigation-controls a.ng-doc-next-page{margin-left:auto}:host .ng-doc-navigation-controls a.ng-doc-prev-page{align-items:flex-start}:host .ng-doc-navigation-controls a.ng-doc-next-page{align-items:flex-end}:host .ng-doc-navigation-controls a .ng-doc-navigation-page-title{--ng-doc-font-weight: 600;--ng-doc-text: var(--ng-doc-link-color)}\n"] }]
63
+ ], template: "<article>\n\t<ng-doc-breadcrumb *ngIf=\"rootPage.pageType === 'guide'\"></ng-doc-breadcrumb>\n\t<div class=\"ng-doc-page-controls\">\n\t\t<a\n\t\t\tng-doc-button-icon\n\t\t\t*ngIf=\"rootPage.editSourceFileUrl\"\n\t\t\t[href]=\"rootPage.editSourceFileUrl\"\n\t\t\ttarget=\"_blank\"\n\t\t\tngDocTooltip=\"Suggest Edits\"\n\t\t>\n\t\t\t<ng-doc-icon icon=\"edit-2\"></ng-doc-icon>\n\t\t</a>\n\t\t<a\n\t\t\tng-doc-button-icon\n\t\t\t*ngIf=\"rootPage.viewSourceFileUrl\"\n\t\t\t[href]=\"rootPage.viewSourceFileUrl\"\n\t\t\ttarget=\"_blank\"\n\t\t\tngDocTooltip=\"View Source\"\n\t\t>\n\t\t\t<ng-doc-icon icon=\"code\"></ng-doc-icon>\n\t\t</a>\n\t</div>\n\n\t<div\n\t\tclass=\"ng-doc-page-wrapper\"\n\t\t[innerHTML]=\"rootPage.pageContent | ngDocSanitizeHtml\"\n\t\tngDocPageProcessor\n\t\t#pageContainer\n\t></div>\n\n\t<div class=\"ng-doc-navigation-controls\" *ngIf=\"rootPage.pageType === 'guide'\">\n\t\t<a class=\"ng-doc-prev-page\" *ngIf=\"prevPage\" [routerLink]=\"prevPage.route\">\n\t\t\t<div class=\"ng-doc-navigation-page-label\" ng-doc-text size=\"small\">\n\t\t\t\t<ng-doc-icon icon=\"arrow-left\" ngDocTextLeft></ng-doc-icon>\n\t\t\t\tPrevious\n\t\t\t</div>\n\t\t\t<div class=\"ng-doc-navigation-page-title\" ng-doc-text>{{ prevPage.title }}</div>\n\t\t</a>\n\t\t<a class=\"ng-doc-next-page\" *ngIf=\"nextPage\" [routerLink]=\"nextPage.route\">\n\t\t\t<div class=\"ng-doc-navigation-page-label\" ng-doc-text size=\"small\">\n\t\t\t\tNext\n\t\t\t\t<ng-doc-icon icon=\"arrow-right\" ngDocTextRight></ng-doc-icon>\n\t\t\t</div>\n\t\t\t<div class=\"ng-doc-navigation-page-title\" ng-doc-text>{{ nextPage.title }}</div>\n\t\t</a>\n\t</div>\n</article>\n\n<ng-template\n\t[ngDocMediaQuery]=\"[mediaQuery.breakpoints.Large, mediaQuery.breakpoints.XLarge]\"\n\t#mediaQuery=\"ngDocMediaQuery\"\n>\n\t<ng-doc-toc [pageContainer]=\"pageContainer\"></ng-doc-toc>\n</ng-template>\n", styles: [":host{display:flex}:host article{position:relative;width:var(--ng-doc-article-width, 100%);margin-left:auto;margin-right:auto;overflow:hidden}:host article .ng-doc-page-controls{position:absolute;display:flex;grid-gap:var(--ng-doc-base-gutter);top:0;right:0}:host ng-doc-toc{--ng-doc-toc-margin: calc(var(--ng-doc-base-gutter) * 3);flex-shrink:0}@media screen and (max-width: 1200px){:host ng-doc-toc{display:none}}:host .ng-doc-navigation-controls{display:flex;margin-top:calc(var(--ng-doc-base-gutter) * 12);border-top:1px solid var(--ng-doc-base-2);padding-top:calc(var(--ng-doc-base-gutter) * 2)}:host .ng-doc-navigation-controls a{display:flex;flex-direction:column;text-decoration:unset;transition:var(--ng-doc-transition);--ng-doc-button-hover-background: var(--ng-doc-base-1);--ng-doc-button-active-background: var(--ng-doc-base-2);--ng-doc-text: var(--ng-doc-base-10);--ng-doc-icon-color: var(--ng-doc-text)}:host .ng-doc-navigation-controls a:hover{opacity:.6}:host .ng-doc-navigation-controls a.ng-doc-next-page{margin-left:auto}:host .ng-doc-navigation-controls a.ng-doc-prev-page{align-items:flex-start}:host .ng-doc-navigation-controls a.ng-doc-next-page{align-items:flex-end}:host .ng-doc-navigation-controls a .ng-doc-navigation-page-title{--ng-doc-font-weight: 600;--ng-doc-text: var(--ng-doc-link-color)}\n"] }]
87
64
  }], ctorParameters: function () { return [{ type: undefined, decorators: [{
88
65
  type: Inject,
89
66
  args: [NG_DOC_CONTEXT]
@@ -1 +1 @@
1
- {"version":3,"file":"ng-doc-app-components-page.mjs","sources":["../../../../libs/app/components/page/page.component.ts","../../../../libs/app/components/page/page.component.html","../../../../libs/app/components/page/ng-doc-app-components-page.ts"],"sourcesContent":["import {NgIf} from '@angular/common';\nimport {ChangeDetectionStrategy, Component, Inject} from '@angular/core';\nimport {Router, RouterLink, UrlTree} from '@angular/router';\nimport {NgDocRootPage} from '@ng-doc/app/classes/root-page';\nimport {NgDocBreadcrumbComponent} from '@ng-doc/app/components/breadcrumb';\nimport {NgDocTocComponent} from '@ng-doc/app/components/toc';\nimport {provideTypeControl} from '@ng-doc/app/helpers';\nimport {NgDocContext, NgDocNavigation} from '@ng-doc/app/interfaces';\nimport {NgDocSanitizeHtmlPipe} from '@ng-doc/app/pipes/sanitize-html';\nimport {\n\tNgDocBlockquoteProcessorDirective,\n\tNgDocCodeProcessorDirective,\n\tNgDocDemoPaneProcessorDirective,\n\tNgDocDemoProcessorDirective,\n\tNgDocIconProcessorDirective,\n\tNgDocLinkProcessorDirective,\n\tNgDocPlaygroundProcessorDirective, NgDocTabsProcessorDirective,\n\tNgDocTooltipProcessorDirective,\n} from '@ng-doc/app/processors';\nimport {NG_DOC_CONTEXT} from '@ng-doc/app/tokens';\nimport {\n\tNgDocBooleanControlComponent,\n\tNgDocNumberControlComponent,\n\tNgDocStringControlComponent,\n\tNgDocTypeAliasControlComponent,\n} from '@ng-doc/app/type-controls';\nimport {\n\tNgDocButtonIconComponent,\n\tNgDocIconComponent,\n\tNgDocMediaQueryDirective,\n\tNgDocTextComponent,\n\tNgDocTextLeftDirective,\n\tNgDocTextRightDirective,\n\tNgDocTooltipDirective,\n} from '@ng-doc/ui-kit';\n\n@Component({\n\tselector: 'ng-doc-page',\n\ttemplateUrl: './page.component.html',\n\tstyleUrls: ['./page.component.scss'],\n\tchangeDetection: ChangeDetectionStrategy.OnPush,\n\tstandalone: true,\n\timports: [\n\t\tNgIf,\n\t\tNgDocBreadcrumbComponent,\n\t\tNgDocButtonIconComponent,\n\t\tNgDocTooltipDirective,\n\t\tNgDocIconComponent,\n\t\tNgDocBlockquoteProcessorDirective,\n\t\tNgDocIconProcessorDirective,\n\t\t/**\n\t\t * The order of the directives is important.\n\t\t * The higher the directive is in the list, the later it will be run.\n\t\t *\n\t\t * So here we want to render demos first, after that we want to render links\n\t\t * and bind tooltips to them.\n\t\t */\n\t\tNgDocTooltipProcessorDirective,\n\t\tNgDocLinkProcessorDirective,\n\t\tNgDocCodeProcessorDirective,\n\t\tNgDocDemoProcessorDirective,\n\t\tNgDocDemoPaneProcessorDirective,\n\t\tNgDocPlaygroundProcessorDirective,\n\t\tNgDocTabsProcessorDirective,\n\t\tRouterLink,\n\t\tNgDocTextComponent,\n\t\tNgDocTextLeftDirective,\n\t\tNgDocTextRightDirective,\n\t\tNgDocMediaQueryDirective,\n\t\tNgDocTocComponent,\n\t\tNgDocSanitizeHtmlPipe,\n\t],\n\tproviders: [\n\t\tprovideTypeControl('NgDocTypeAlias', NgDocTypeAliasControlComponent, {order: 10}),\n\t\tprovideTypeControl('string', NgDocStringControlComponent, {order: 20}),\n\t\tprovideTypeControl('number', NgDocNumberControlComponent, {order: 30}),\n\t\tprovideTypeControl('boolean', NgDocBooleanControlComponent, {hideLabel: true, order: 40}),\n\t],\n})\nexport class NgDocPageComponent {\n\treadonly prevPage?: NgDocNavigation;\n\treadonly nextPage?: NgDocNavigation;\n\n\tconstructor(\n\t\t@Inject(NG_DOC_CONTEXT)\n\t\tprivate readonly context: NgDocContext,\n\t\tprivate readonly router: Router,\n\t\treadonly rootPage: NgDocRootPage,\n\t) {\n\t\tconst flatPages = this.flatPages(this.context.navigation);\n\n\t\tthis.prevPage = flatPages[flatPages.findIndex((item: NgDocNavigation) => this.url === item.route) - 1];\n\t\tthis.nextPage = flatPages[flatPages.findIndex((item: NgDocNavigation) => this.url === item.route) + 1];\n\t}\n\n\tprivate flatPages(items: NgDocNavigation[]): NgDocNavigation[] {\n\t\treturn items.map((item: NgDocNavigation) => [item.children?.length ? this.flatPages(item.children) : item]).flat(2);\n\t}\n\n\tprivate get url(): string {\n\t\tconst urlTree: UrlTree = this.router.parseUrl(this.router.url);\n\n\t\turlTree.queryParams = {};\n\t\turlTree.fragment = null;\n\n\t\treturn urlTree.toString();\n\t}\n}\n","<article>\n\t<ng-doc-breadcrumb *ngIf=\"rootPage.pageType === 'guide'\"></ng-doc-breadcrumb>\n\t<div class=\"ng-doc-page-controls\">\n\t\t<a\n\t\t\tng-doc-button-icon\n\t\t\t*ngIf=\"rootPage.editSourceFileUrl\"\n\t\t\t[href]=\"rootPage.editSourceFileUrl\"\n\t\t\ttarget=\"_blank\"\n\t\t\tngDocTooltip=\"Suggest Edits\"\n\t\t>\n\t\t\t<ng-doc-icon icon=\"edit-2\"></ng-doc-icon>\n\t\t</a>\n\t\t<a\n\t\t\tng-doc-button-icon\n\t\t\t*ngIf=\"rootPage.viewSourceFileUrl\"\n\t\t\t[href]=\"rootPage.viewSourceFileUrl\"\n\t\t\ttarget=\"_blank\"\n\t\t\tngDocTooltip=\"View Source\"\n\t\t>\n\t\t\t<ng-doc-icon icon=\"code\"></ng-doc-icon>\n\t\t</a>\n\t</div>\n\n\t<div\n\t\tclass=\"ng-doc-page-wrapper\"\n\t\t[innerHTML]=\"rootPage.pageContent | ngDocSanitizeHtml\"\n\t\tngDocBlockquoteProcessor\n\t\tngDocLinkProcessor\n\t\tngDocCodeProcessor\n\t\tngDocIconProcessor\n\t\tngDocTooltipProcessor\n\t\tngDocDemoProcessor\n\t\tngDocDemoPaneProcessor\n\t\tngDocPlaygroundProcessor\n\t\tngDocTabsProcessor\n\t\t#pageContainer\n\t></div>\n\n\t<div class=\"ng-doc-navigation-controls\" *ngIf=\"rootPage.pageType === 'guide'\">\n\t\t<a class=\"ng-doc-prev-page\" *ngIf=\"prevPage\" [routerLink]=\"prevPage.route\">\n\t\t\t<div class=\"ng-doc-navigation-page-label\" ng-doc-text size=\"small\">\n\t\t\t\t<ng-doc-icon icon=\"arrow-left\" ngDocTextLeft></ng-doc-icon>\n\t\t\t\tPrevious\n\t\t\t</div>\n\t\t\t<div class=\"ng-doc-navigation-page-title\" ng-doc-text>{{ prevPage.title }}</div>\n\t\t</a>\n\t\t<a class=\"ng-doc-next-page\" *ngIf=\"nextPage\" [routerLink]=\"nextPage.route\">\n\t\t\t<div class=\"ng-doc-navigation-page-label\" ng-doc-text size=\"small\">\n\t\t\t\tNext\n\t\t\t\t<ng-doc-icon icon=\"arrow-right\" ngDocTextRight></ng-doc-icon>\n\t\t\t</div>\n\t\t\t<div class=\"ng-doc-navigation-page-title\" ng-doc-text>{{ nextPage.title }}</div>\n\t\t</a>\n\t</div>\n</article>\n\n<ng-template\n\t[ngDocMediaQuery]=\"[mediaQuery.breakpoints.Large, mediaQuery.breakpoints.XLarge]\"\n\t#mediaQuery=\"ngDocMediaQuery\"\n>\n\t<ng-doc-toc [pageContainer]=\"pageContainer\"></ng-doc-toc>\n</ng-template>\n","/**\n * Generated bundle index. Do not edit.\n */\n\nexport * from './index';\n"],"names":[],"mappings":";;;;;;;;;;;;;;;AAoCA,MA2Ca,kBAAkB,CAAA;AAI9B,IAAA,WAAA,CAEkB,OAAqB,EACrB,MAAc,EACtB,QAAuB,EAAA;QAFf,IAAO,CAAA,OAAA,GAAP,OAAO,CAAc;QACrB,IAAM,CAAA,MAAA,GAAN,MAAM,CAAQ;QACtB,IAAQ,CAAA,QAAA,GAAR,QAAQ,CAAe;AAEhC,QAAA,MAAM,SAAS,GAAG,IAAI,CAAC,SAAS,CAAC,IAAI,CAAC,OAAO,CAAC,UAAU,CAAC,CAAC;QAE1D,IAAI,CAAC,QAAQ,GAAG,SAAS,CAAC,SAAS,CAAC,SAAS,CAAC,CAAC,IAAqB,KAAK,IAAI,CAAC,GAAG,KAAK,IAAI,CAAC,KAAK,CAAC,GAAG,CAAC,CAAC,CAAC;QACvG,IAAI,CAAC,QAAQ,GAAG,SAAS,CAAC,SAAS,CAAC,SAAS,CAAC,CAAC,IAAqB,KAAK,IAAI,CAAC,GAAG,KAAK,IAAI,CAAC,KAAK,CAAC,GAAG,CAAC,CAAC,CAAC;KACvG;AAEO,IAAA,SAAS,CAAC,KAAwB,EAAA;AACzC,QAAA,OAAO,KAAK,CAAC,GAAG,CAAC,CAAC,IAAqB,KAAK,C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4B,EAAE,EAAC,SAAS,EAAE,IAAI,EAAE,KAAK,EAAE,EAAE,EAAC,CAAC;AACzF,qBAAA,EAAA,QAAA,EAAA,yiEAAA,EAAA,MAAA,EAAA,CAAA,8yCAAA,CAAA,EAAA,CAAA;;0BAOC,MAAM;2BAAC,cAAc,CAAA;;;AEpFxB;;AAEG;;;;"}
1
+ {"version":3,"file":"ng-doc-app-components-page.mjs","sources":["../../../../libs/app/components/page/page.component.ts","../../../../libs/app/components/page/page.component.html","../../../../libs/app/components/page/ng-doc-app-components-page.ts"],"sourcesContent":["import {NgIf} from '@angular/common';\nimport {ChangeDetectionStrategy, Component, Inject} from '@angular/core';\nimport {Router, RouterLink, UrlTree} from '@angular/router';\nimport {NgDocRootPage} from '@ng-doc/app/classes/root-page';\nimport {NgDocBreadcrumbComponent} from '@ng-doc/app/components/breadcrumb';\nimport {NgDocTocComponent} from '@ng-doc/app/components/toc';\nimport {provideTypeControl} from '@ng-doc/app/helpers';\nimport {NgDocContext, NgDocNavigation} from '@ng-doc/app/interfaces';\nimport {NgDocSanitizeHtmlPipe} from '@ng-doc/app/pipes/sanitize-html';\nimport {NgDocPageProcessorDirective} from '@ng-doc/app/processors';\nimport {NG_DOC_CONTEXT} from '@ng-doc/app/tokens';\nimport {\n\tNgDocBooleanControlComponent,\n\tNgDocNumberControlComponent,\n\tNgDocStringControlComponent,\n\tNgDocTypeAliasControlComponent,\n} from '@ng-doc/app/type-controls';\nimport {\n\tNgDocButtonIconComponent,\n\tNgDocIconComponent,\n\tNgDocMediaQueryDirective,\n\tNgDocTextComponent,\n\tNgDocTextLeftDirective,\n\tNgDocTextRightDirective,\n\tNgDocTooltipDirective,\n} from '@ng-doc/ui-kit';\n\n@Component({\n\tselector: 'ng-doc-page',\n\ttemplateUrl: './page.component.html',\n\tstyleUrls: ['./page.component.scss'],\n\tchangeDetection: ChangeDetectionStrategy.OnPush,\n\tstandalone: true,\n\timports: [\n\t\tNgIf,\n\t\tNgDocBreadcrumbComponent,\n\t\tNgDocButtonIconComponent,\n\t\tNgDocTooltipDirective,\n\t\tNgDocIconComponent,\n\t\tRouterLink,\n\t\tNgDocTextComponent,\n\t\tNgDocTextLeftDirective,\n\t\tNgDocTextRightDirective,\n\t\tNgDocMediaQueryDirective,\n\t\tNgDocTocComponent,\n\t\tNgDocSanitizeHtmlPipe,\n\t\tNgDocPageProcessorDirective,\n\t],\n\tproviders: [\n\t\tprovideTypeControl('NgDocTypeAlias', NgDocTypeAliasControlComponent, {order: 10}),\n\t\tprovideTypeControl('string', NgDocStringControlComponent, {order: 20}),\n\t\tprovideTypeControl('number', NgDocNumberControlComponent, {order: 30}),\n\t\tprovideTypeControl('boolean', NgDocBooleanControlComponent, {hideLabel: true, order: 40}),\n\t],\n})\nexport class NgDocPageComponent {\n\treadonly prevPage?: NgDocNavigation;\n\treadonly nextPage?: NgDocNavigation;\n\n\tconstructor(\n\t\t@Inject(NG_DOC_CONTEXT)\n\t\tprivate readonly context: NgDocContext,\n\t\tprivate readonly router: Router,\n\t\treadonly rootPage: NgDocRootPage,\n\t) {\n\t\tconst flatPages = this.flatPages(this.context.navigation);\n\n\t\tthis.prevPage = flatPages[flatPages.findIndex((item: NgDocNavigation) => this.url === item.route) - 1];\n\t\tthis.nextPage = flatPages[flatPages.findIndex((item: NgDocNavigation) => this.url === item.route) + 1];\n\t}\n\n\tprivate flatPages(items: NgDocNavigation[]): NgDocNavigation[] {\n\t\treturn items.map((item: NgDocNavigation) => [item.children?.length ? this.flatPages(item.children) : item]).flat(2);\n\t}\n\n\tprivate get url(): string {\n\t\tconst urlTree: UrlTree = this.router.parseUrl(this.router.url);\n\n\t\turlTree.queryParams = {};\n\t\turlTree.fragment = null;\n\n\t\treturn urlTree.toString();\n\t}\n}\n","<article>\n\t<ng-doc-breadcrumb *ngIf=\"rootPage.pageType === 'guide'\"></ng-doc-breadcrumb>\n\t<div class=\"ng-doc-page-controls\">\n\t\t<a\n\t\t\tng-doc-button-icon\n\t\t\t*ngIf=\"rootPage.editSourceFileUrl\"\n\t\t\t[href]=\"rootPage.editSourceFileUrl\"\n\t\t\ttarget=\"_blank\"\n\t\t\tngDocTooltip=\"Suggest Edits\"\n\t\t>\n\t\t\t<ng-doc-icon icon=\"edit-2\"></ng-doc-icon>\n\t\t</a>\n\t\t<a\n\t\t\tng-doc-button-icon\n\t\t\t*ngIf=\"rootPage.viewSourceFileUrl\"\n\t\t\t[href]=\"rootPage.viewSourceFileUrl\"\n\t\t\ttarget=\"_blank\"\n\t\t\tngDocTooltip=\"View Source\"\n\t\t>\n\t\t\t<ng-doc-icon icon=\"code\"></ng-doc-icon>\n\t\t</a>\n\t</div>\n\n\t<div\n\t\tclass=\"ng-doc-page-wrapper\"\n\t\t[innerHTML]=\"rootPage.pageContent | ngDocSanitizeHtml\"\n\t\tngDocPageProcessor\n\t\t#pageContainer\n\t></div>\n\n\t<div class=\"ng-doc-navigation-controls\" *ngIf=\"rootPage.pageType === 'guide'\">\n\t\t<a class=\"ng-doc-prev-page\" *ngIf=\"prevPage\" [routerLink]=\"prevPage.route\">\n\t\t\t<div class=\"ng-doc-navigation-page-label\" ng-doc-text size=\"small\">\n\t\t\t\t<ng-doc-icon icon=\"arrow-left\" ngDocTextLeft></ng-doc-icon>\n\t\t\t\tPrevious\n\t\t\t</div>\n\t\t\t<div class=\"ng-doc-navigation-page-title\" ng-doc-text>{{ prevPage.title }}</div>\n\t\t</a>\n\t\t<a class=\"ng-doc-next-page\" *ngIf=\"nextPage\" [routerLink]=\"nextPage.route\">\n\t\t\t<div class=\"ng-doc-navigation-page-label\" ng-doc-text size=\"small\">\n\t\t\t\tNext\n\t\t\t\t<ng-doc-icon icon=\"arrow-right\" ngDocTextRight></ng-doc-icon>\n\t\t\t</div>\n\t\t\t<div class=\"ng-doc-navigation-page-title\" ng-doc-text>{{ nextPage.title }}</div>\n\t\t</a>\n\t</div>\n</article>\n\n<ng-template\n\t[ngDocMediaQuery]=\"[mediaQuery.breakpoints.Large, mediaQuery.breakpoints.XLarge]\"\n\t#mediaQuery=\"ngDocMediaQuery\"\n>\n\t<ng-doc-toc [pageContainer]=\"pageContainer\"></ng-doc-toc>\n</ng-template>\n","/**\n * Generated bundle index. Do not edit.\n */\n\nexport * from './index';\n"],"names":[],"mappings":";;;;;;;;;;;;;;;AA2BA,MA4Ba,kBAAkB,CAAA;AAI9B,IAAA,WAAA,CAEkB,OAAqB,EACrB,MAAc,EACtB,QAAuB,EAAA;QAFf,IAAO,CAAA,OAAA,GAAP,OAAO,CAAc;QACrB,IAAM,CAAA,MAAA,GAAN,MAAM,CAAQ;QACtB,IAAQ,CAAA,QAAA,GAAR,QAAQ,CAAe;AAEhC,QAAA,MAAM,SAAS,GAAG,IAAI,CAAC,SAAS,CAAC,IAAI,CAAC,OAAO,CAAC,UAAU,CAAC,CAAC;QAE1D,IAAI,CAAC,QAAQ,GAAG,SAAS,CAAC,SAAS,CAAC,SAAS,CAAC,CAAC,IAAqB,KAAK,IAAI,CAAC,GAAG,KAAK,IAAI,CAAC,KAAK,CAAC,GAAG,CAAC,CAAC,CAAC;QACvG,IAAI,CAAC,QAAQ,GAAG,SAAS,CAAC,SAAS,CAAC,SAAS,CAAC,CAAC,IAAqB,KAAK,IAAI,CAAC,GAAG,KAAK,IAAI,CAAC,KAAK,CAAC,GAAG,CAAC,CAAC,CAAC;KACvG;AAEO,IAAA,SAAS,CAAC,KAAwB,EAAA;AACzC,QAAA,OAAO,KAAK,CAAC,GAAG,CAAC,CAAC,IAAqB,KAAK,CAAC,IAAI,CAAC,QAAQ,EAAE,MAAM,GAAG,IAAI,CAAC,SAAS,CAAC,IAAI,CAAC,QAAQ,CAAC,GAAG,IAAI,CAAC,CAAC,CAAC,IAAI,CAAC,CAAC,CAAC,CAAC;KACpH;AAED,IAAA,IAAY,GAAG,GAAA;AACd,QAAA,MAAM,OAAO,GAAY,IAAI,CAAC,MAAM,CAAC,QAAQ,CAAC,IAAI,CAAC,MAAM,CAAC,GAAG,CAAC,CAAC;AAE/D,QAAA,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EAAE,KAAK,EAAE,EAAE,EAAC,CAAC;AACzF,qBAAA,EAAA,QAAA,EAAA,s1DAAA,EAAA,MAAA,EAAA,CAAA,8yCAAA,CAAA,EAAA,CAAA;;0BAOC,MAAM;2BAAC,cAAc,CAAA;;;AE5DxB;;AAEG;;;;"}
@@ -1,47 +1,23 @@
1
1
  import * as i0 from '@angular/core';
2
- import { Directive, Input, ViewContainerRef, Injector, Component, ChangeDetectionStrategy, ViewChild, HostBinding, EventEmitter, isDevMode, Output } from '@angular/core';
2
+ import { ViewContainerRef, Injector, Component, ChangeDetectionStrategy, Input, ViewChild, HostBinding, EventEmitter, isDevMode, Output, inject, Directive } from '@angular/core';
3
+ import { stringify, objectKeys as objectKeys$1, isPresent, extractValueOrThrow, extractFunctionDefaults } from '@ng-doc/core';
3
4
  import { AsyncPipe, NgIf, NgFor, KeyValuePipe } from '@angular/common';
4
5
  import * as i2 from '@angular/forms';
5
6
  import { FormsModule } from '@angular/forms';
6
7
  import * as i1$1 from '@ng-doc/app/classes/root-page';
7
- import { extractValue } from '@ng-doc/core/helpers/extract-value';
8
8
  import { objectKeys } from '@ng-doc/core/helpers/object-keys';
9
- import { NgDocLabelComponent, NgDocTooltipDirective, NgDocTextComponent, NgDocButtonComponent, NgDocCheckboxComponent, NgDocIconComponent, NgDocTextRightDirective, NgDocBindPipe, NgDocExecutePipe, NgDocAsArrayPipe } from '@ng-doc/ui-kit';
9
+ import { NgDocSmoothResizeComponent, NgDocLetDirective, NgDocLabelComponent, NgDocTooltipDirective, NgDocTextComponent, NgDocButtonComponent, NgDocCheckboxComponent, NgDocIconComponent, NgDocTextRightDirective, NgDocBindPipe, NgDocExecutePipe, NgDocAsArrayPipe } from '@ng-doc/ui-kit';
10
10
  import { __decorate, __metadata } from 'tslib';
11
11
  import { NgDocDemoDisplayerComponent } from '@ng-doc/app/components/demo-displayer';
12
12
  import { getPlaygroundDemoToken, formatHtml, isPlaygroundProperty, getTokenForType } from '@ng-doc/app/helpers';
13
13
  import { buildPlaygroundDemoPipeTemplate, buildPlaygroundDemoTemplate } from '@ng-doc/core/helpers/build-playground-demo-template';
14
14
  import { untilDestroyed, UntilDestroy } from '@ngneat/until-destroy';
15
15
  import { of, Subject, from } from 'rxjs';
16
- import { takeUntil, startWith, pluck } from 'rxjs/operators';
16
+ import { takeUntil, startWith, map } from 'rxjs/operators';
17
17
  import * as i1 from '@angular/cdk/layout';
18
18
  import { Breakpoints } from '@angular/cdk/layout';
19
- import { objectKeys as objectKeys$1, isPresent, extractValueOrThrow } from '@ng-doc/core';
20
19
  import { NgDocSanitizeHtmlPipe } from '@ng-doc/app/pipes';
21
20
 
22
- /**
23
- * Base class for playgrounds components.
24
- */
25
- class NgDocBasePlayground {
26
- constructor() {
27
- this.properties = {};
28
- this.data = {};
29
- this.content = {};
30
- }
31
- static { this.selector = 'unknown'; }
32
- static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "16.0.0", ngImport: i0, type: NgDocBasePlayground, deps: [], target: i0.ɵɵFactoryTarget.Directive }); }
33
- static { this.ɵdir = i0.ɵɵngDeclareDirective({ minVersion: "14.0.0", version: "16.0.0", type: NgDocBasePlayground, inputs: { properties: "properties", data: "data", content: "content" }, ngImport: i0 }); }
34
- }
35
- i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "16.0.0", ngImport: i0, type: NgDocBasePlayground, decorators: [{
36
- type: Directive
37
- }], propDecorators: { properties: [{
38
- type: Input
39
- }], data: [{
40
- type: Input
41
- }], content: [{
42
- type: Input
43
- }] } });
44
-
45
21
  let NgDocPlaygroundDemoComponent = class NgDocPlaygroundDemoComponent {
46
22
  constructor(injector) {
47
23
  this.injector = injector;
@@ -49,11 +25,12 @@ let NgDocPlaygroundDemoComponent = class NgDocPlaygroundDemoComponent {
49
25
  this.pipeName = '';
50
26
  this.selector = '';
51
27
  this.recreateDemo = false;
28
+ this.expanded = false;
52
29
  this.code = of('');
53
30
  this.unsubscribe$ = new Subject();
54
31
  }
55
32
  ngOnChanges({ form, id }) {
56
- if (form && id) {
33
+ if (form || id) {
57
34
  this.unsubscribe$.next();
58
35
  const demoInjector = getPlaygroundDemoToken(this.id);
59
36
  if (demoInjector) {
@@ -73,6 +50,7 @@ let NgDocPlaygroundDemoComponent = class NgDocPlaygroundDemoComponent {
73
50
  if (data) {
74
51
  this.demoRef?.setInput('properties', data.properties ?? {});
75
52
  this.demoRef?.setInput('content', data.content ?? {});
53
+ this.demoRef?.setInput('actionData', this.configuration?.data ?? {});
76
54
  }
77
55
  this.updateCodeView();
78
56
  }
@@ -101,14 +79,10 @@ let NgDocPlaygroundDemoComponent = class NgDocPlaygroundDemoComponent {
101
79
  getActiveInputs() {
102
80
  const formData = this.form?.controls.properties.value ?? {};
103
81
  return objectKeys(formData).reduce((result, key) => {
104
- const property = this.properties?.[key];
105
- if (property) {
106
- const value = formData[key];
107
- const isString = typeof value === 'string';
108
- const inputValue = isString ? `'${value}'` : `${JSON.stringify(value)}`;
109
- if ((property.default ?? '') !== inputValue) {
110
- result[property.inputName] = inputValue;
111
- }
82
+ const value = formData[key];
83
+ const property = this.demoRef?.instance?.defaultValues[key];
84
+ if (property !== value) {
85
+ result[key] = stringify(value).replace(/"/g, `'`);
112
86
  }
113
87
  return result;
114
88
  }, {});
@@ -118,7 +92,7 @@ let NgDocPlaygroundDemoComponent = class NgDocPlaygroundDemoComponent {
118
92
  this.unsubscribe$.complete();
119
93
  }
120
94
  static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "16.0.0", ngImport: i0, type: NgDocPlaygroundDemoComponent, deps: [{ token: i0.Injector }], target: i0.ɵɵFactoryTarget.Component }); }
121
- static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "16.0.0", type: NgDocPlaygroundDemoComponent, isStandalone: true, selector: "ng-doc-playground-demo", inputs: { id: "id", pipeName: "pipeName", selector: "selector", configuration: "configuration", properties: "properties", recreateDemo: "recreateDemo", form: "form" }, viewQueries: [{ propertyName: "demoOutlet", first: true, predicate: ["demoOutlet"], descendants: true, read: ViewContainerRef, static: true }], usesOnChanges: true, ngImport: i0, template: "<ng-doc-demo-displayer [code]=\"(code | async) ?? ''\" [border]=\"false\" language=\"html\">\n\t<ng-container #demoOutlet></ng-container>\n</ng-doc-demo-displayer>\n", styles: [":host{display:block;border:var(--ng-doc-demo-displayer-border);border-radius:var(--ng-doc-demo-displayer-border-radius);overflow:hidden}:host:not(:last-child){border-bottom:0;border-bottom-left-radius:0;border-bottom-right-radius:0}:host:not(:first-child){border-top-left-radius:0;border-top-right-radius:0}\n"], dependencies: [{ kind: "component", type: NgDocDemoDisplayerComponent, selector: "ng-doc-demo-displayer", inputs: ["codeContent", "code", "language", "container", "border", "expanded"] }, { kind: "pipe", type: AsyncPipe, name: "async" }], changeDetection: i0.ChangeDetectionStrategy.OnPush }); }
95
+ static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "16.0.0", type: NgDocPlaygroundDemoComponent, isStandalone: true, selector: "ng-doc-playground-demo", inputs: { id: "id", pipeName: "pipeName", selector: "selector", configuration: "configuration", properties: "properties", recreateDemo: "recreateDemo", form: "form", expanded: "expanded" }, viewQueries: [{ propertyName: "demoOutlet", first: true, predicate: ["demoOutlet"], descendants: true, read: ViewContainerRef, static: true }], usesOnChanges: true, ngImport: i0, template: "<ng-doc-smooth-resize *ngDocLet=\"code | async as codeContent\" [trigger]=\"codeContent\">\n\t<ng-doc-demo-displayer\n\t\t[code]=\"codeContent ?? ''\"\n\t\t[border]=\"false\"\n\t\t[expanded]=\"expanded\"\n\t\tlanguage=\"html\"\n\t>\n\t\t<ng-container #demoOutlet></ng-container>\n\t</ng-doc-demo-displayer>\n</ng-doc-smooth-resize>\n", styles: [":host{display:block;border:var(--ng-doc-demo-displayer-border);border-radius:var(--ng-doc-demo-displayer-border-radius);overflow:hidden}:host:not(:last-child){border-bottom:0;border-bottom-left-radius:0;border-bottom-right-radius:0}:host:not(:first-child){border-top-left-radius:0;border-top-right-radius:0}\n"], dependencies: [{ kind: "component", type: NgDocDemoDisplayerComponent, selector: "ng-doc-demo-displayer", inputs: ["codeContent", "code", "language", "container", "border", "expanded"] }, { kind: "pipe", type: AsyncPipe, name: "async" }, { kind: "component", type: NgDocSmoothResizeComponent, selector: "ng-doc-smooth-resize", inputs: ["trigger", "animateOpacity"] }, { kind: "directive", type: NgDocLetDirective, selector: "[ngDocLet]", inputs: ["ngDocLet"] }], changeDetection: i0.ChangeDetectionStrategy.OnPush }); }
122
96
  };
123
97
  NgDocPlaygroundDemoComponent = __decorate([
124
98
  UntilDestroy(),
@@ -126,7 +100,7 @@ NgDocPlaygroundDemoComponent = __decorate([
126
100
  ], NgDocPlaygroundDemoComponent);
127
101
  i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "16.0.0", ngImport: i0, type: NgDocPlaygroundDemoComponent, decorators: [{
128
102
  type: Component,
129
- args: [{ selector: 'ng-doc-playground-demo', changeDetection: ChangeDetectionStrategy.OnPush, standalone: true, imports: [NgDocDemoDisplayerComponent, AsyncPipe], template: "<ng-doc-demo-displayer [code]=\"(code | async) ?? ''\" [border]=\"false\" language=\"html\">\n\t<ng-container #demoOutlet></ng-container>\n</ng-doc-demo-displayer>\n", styles: [":host{display:block;border:var(--ng-doc-demo-displayer-border);border-radius:var(--ng-doc-demo-displayer-border-radius);overflow:hidden}:host:not(:last-child){border-bottom:0;border-bottom-left-radius:0;border-bottom-right-radius:0}:host:not(:first-child){border-top-left-radius:0;border-top-right-radius:0}\n"] }]
103
+ args: [{ selector: 'ng-doc-playground-demo', changeDetection: ChangeDetectionStrategy.OnPush, standalone: true, imports: [NgDocDemoDisplayerComponent, AsyncPipe, NgDocSmoothResizeComponent, NgDocLetDirective], template: "<ng-doc-smooth-resize *ngDocLet=\"code | async as codeContent\" [trigger]=\"codeContent\">\n\t<ng-doc-demo-displayer\n\t\t[code]=\"codeContent ?? ''\"\n\t\t[border]=\"false\"\n\t\t[expanded]=\"expanded\"\n\t\tlanguage=\"html\"\n\t>\n\t\t<ng-container #demoOutlet></ng-container>\n\t</ng-doc-demo-displayer>\n</ng-doc-smooth-resize>\n", styles: [":host{display:block;border:var(--ng-doc-demo-displayer-border);border-radius:var(--ng-doc-demo-displayer-border-radius);overflow:hidden}:host:not(:last-child){border-bottom:0;border-bottom-left-radius:0;border-bottom-right-radius:0}:host:not(:first-child){border-top-left-radius:0;border-top-right-radius:0}\n"] }]
130
104
  }], ctorParameters: function () { return [{ type: i0.Injector }]; }, propDecorators: { id: [{
131
105
  type: Input
132
106
  }], pipeName: [{
@@ -141,6 +115,8 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "16.0.0", ngImpor
141
115
  type: Input
142
116
  }], form: [{
143
117
  type: Input
118
+ }], expanded: [{
119
+ type: Input
144
120
  }], demoOutlet: [{
145
121
  type: ViewChild,
146
122
  args: ['demoOutlet', { static: true, read: ViewContainerRef }]
@@ -150,8 +126,8 @@ class NgDocPlaygroundPropertyComponent {
150
126
  constructor() {
151
127
  this.name = '';
152
128
  }
153
- ngOnChanges({ property, control, typeControl }) {
154
- if ((property || control || typeControl) && this.property && this.typeControl) {
129
+ ngOnChanges({ property, control, typeControl, defaultValue }) {
130
+ if ((property || control || typeControl || defaultValue) && this.property && this.typeControl) {
155
131
  this.propertyTypeControl?.destroy();
156
132
  this.propertyTypeControl = undefined;
157
133
  if (this.typeControl && this.propertyOutlet) {
@@ -161,17 +137,15 @@ class NgDocPlaygroundPropertyComponent {
161
137
  this.propertyTypeControl.instance.options = isPlaygroundProperty(this.property)
162
138
  ? this.property.options
163
139
  : undefined;
164
- this.propertyTypeControl.instance.default = isPlaygroundProperty(this.property)
165
- ? this.property.default
166
- : undefined;
140
+ this.propertyTypeControl.instance.default = this.defaultValue;
167
141
  this.propertyTypeControl.instance.writeValue(this.control?.value);
168
142
  this.option = this.typeControl.options;
169
143
  }
170
- }
171
- if (control) {
172
- this.control?.registerOnChange((value) => this.propertyTypeControl?.instance?.writeValue(value));
173
- this.propertyTypeControl?.instance.registerOnChange((value) => this.control?.setValue(value));
174
- this.propertyTypeControl?.instance.registerOnTouched(() => this.control?.markAsTouched());
144
+ if (this.control) {
145
+ this.control?.registerOnChange((value) => this.propertyTypeControl?.instance?.writeValue(value));
146
+ this.propertyTypeControl?.instance.registerOnChange((value) => this.control?.setValue(value));
147
+ this.propertyTypeControl?.instance.registerOnTouched(() => this.control?.markAsTouched());
148
+ }
175
149
  }
176
150
  }
177
151
  get hasPropertyControl() {
@@ -181,7 +155,7 @@ class NgDocPlaygroundPropertyComponent {
181
155
  return this.property && isPlaygroundProperty(this.property) ? this.property.description ?? '' : '';
182
156
  }
183
157
  static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "16.0.0", ngImport: i0, type: NgDocPlaygroundPropertyComponent, deps: [], target: i0.ɵɵFactoryTarget.Component }); }
184
- static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "16.0.0", type: NgDocPlaygroundPropertyComponent, isStandalone: true, selector: "ng-doc-playground-property", inputs: { name: "name", property: "property", typeControl: "typeControl", control: "control" }, host: { properties: { "attr.data-has-property-control": "this.hasPropertyControl" } }, viewQueries: [{ propertyName: "propertyOutlet", first: true, predicate: ["propertyOutlet"], descendants: true, read: ViewContainerRef, static: true }], usesOnChanges: true, ngImport: i0, template: "<label [ng-doc-label]=\"option?.hideLabel ? '' : labelContent\">\n\t<ng-template #labelContent>\n\t\t<span [ngDocTooltip]=\"tooltipTemplate\" [canOpen]=\"!!tooltipContent\"\n\t\t\t [positions]=\"['left-center', 'top-right', 'bottom-right']\">{{name}}</span>\n\t\t<ng-template #tooltipTemplate>\n\t\t\t<div [innerHTML]=\"tooltipContent | ngDocSanitizeHtml\"></div>\n\t\t</ng-template>\n\t</ng-template>\n\t<ng-container #propertyOutlet></ng-container>\n</label>\n", styles: [":host{display:block}:host[data-has-property-control=false]{display:none}\n"], dependencies: [{ kind: "component", type: NgDocLabelComponent, selector: "label[ng-doc-label]", inputs: ["ng-doc-label", "align"] }, { kind: "directive", type: NgDocTooltipDirective, selector: "[ngDocTooltip]", inputs: ["ngDocTooltip", "delay", "displayOrigin", "pointerOrigin", "positions", "canOpen", "panelClass", "minHeight", "maxHeight", "height", "minWidth", "maxWidth", "width"], outputs: ["beforeOpen", "afterOpen", "beforeClose", "afterClose"], exportAs: ["ngDocTooltip"] }, { kind: "pipe", type: NgDocSanitizeHtmlPipe, name: "ngDocSanitizeHtml" }], changeDetection: i0.ChangeDetectionStrategy.OnPush }); }
158
+ static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "16.0.0", type: NgDocPlaygroundPropertyComponent, isStandalone: true, selector: "ng-doc-playground-property", inputs: { name: "name", property: "property", typeControl: "typeControl", control: "control", defaultValue: "defaultValue" }, host: { properties: { "attr.data-has-property-control": "this.hasPropertyControl" } }, viewQueries: [{ propertyName: "propertyOutlet", first: true, predicate: ["propertyOutlet"], descendants: true, read: ViewContainerRef, static: true }], usesOnChanges: true, ngImport: i0, template: "<label [ng-doc-label]=\"option?.hideLabel ? '' : labelContent\">\n\t<ng-template #labelContent>\n\t\t<span [ngDocTooltip]=\"tooltipTemplate\" [canOpen]=\"!!tooltipContent\"\n\t\t\t [positions]=\"['left-center', 'top-right', 'bottom-right']\">{{name}}</span>\n\t\t<ng-template #tooltipTemplate>\n\t\t\t<div [innerHTML]=\"tooltipContent | ngDocSanitizeHtml\"></div>\n\t\t</ng-template>\n\t</ng-template>\n\t<ng-container #propertyOutlet></ng-container>\n</label>\n", styles: [":host{display:block}:host[data-has-property-control=false]{display:none}\n"], dependencies: [{ kind: "component", type: NgDocLabelComponent, selector: "label[ng-doc-label]", inputs: ["ng-doc-label", "align"] }, { kind: "directive", type: NgDocTooltipDirective, selector: "[ngDocTooltip]", inputs: ["ngDocTooltip", "delay", "displayOrigin", "pointerOrigin", "positions", "canOpen", "panelClass", "minHeight", "maxHeight", "height", "minWidth", "maxWidth", "width"], outputs: ["beforeOpen", "afterOpen", "beforeClose", "afterClose"], exportAs: ["ngDocTooltip"] }, { kind: "pipe", type: NgDocSanitizeHtmlPipe, name: "ngDocSanitizeHtml" }], changeDetection: i0.ChangeDetectionStrategy.OnPush }); }
185
159
  }
186
160
  i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "16.0.0", ngImport: i0, type: NgDocPlaygroundPropertyComponent, decorators: [{
187
161
  type: Component,
@@ -194,6 +168,8 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "16.0.0", ngImpor
194
168
  type: Input
195
169
  }], control: [{
196
170
  type: Input
171
+ }], defaultValue: [{
172
+ type: Input
197
173
  }], propertyOutlet: [{
198
174
  type: ViewChild,
199
175
  args: ['propertyOutlet', { read: ViewContainerRef, static: true }]
@@ -206,13 +182,16 @@ class NgDocPlaygroundPropertiesComponent {
206
182
  constructor(breakpointObserver, injector) {
207
183
  this.breakpointObserver = breakpointObserver;
208
184
  this.injector = injector;
185
+ this.hideSidePanel = false;
209
186
  this.recreateDemo = false;
210
187
  this.recreateDemoChange = new EventEmitter();
211
188
  this.resetForm = new EventEmitter();
212
189
  this.breakpoints = [Breakpoints.XSmall];
213
190
  this.propertyControls = [];
214
191
  this.contentTypeControl = this.getControlForType('boolean');
215
- this.observer = this.breakpointObserver.observe(this.breakpoints).pipe(pluck('matches'));
192
+ this.observer = this.breakpointObserver
193
+ .observe(this.breakpoints)
194
+ .pipe(map((state) => state.matches));
216
195
  }
217
196
  ngOnChanges({ properties }) {
218
197
  if (properties && this.properties) {
@@ -282,7 +261,7 @@ class NgDocPlaygroundPropertiesComponent {
282
261
  return undefined;
283
262
  }
284
263
  static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "16.0.0", ngImport: i0, type: NgDocPlaygroundPropertiesComponent, deps: [{ token: i1.BreakpointObserver }, { token: i0.Injector }], target: i0.ɵɵFactoryTarget.Component }); }
285
- static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "16.0.0", type: NgDocPlaygroundPropertiesComponent, isStandalone: true, selector: "ng-doc-playground-properties", inputs: { form: "form", properties: "properties", dynamicContent: "dynamicContent", recreateDemo: "recreateDemo" }, outputs: { recreateDemoChange: "recreateDemoChange", resetForm: "resetForm" }, usesOnChanges: true, ngImport: i0, template: "<div class=\"ng-doc-playground-properties-wrapper\" [class.vertical]=\"observer | async\">\n\t<div class=\"ng-doc-playground-demos\">\n\t\t<ng-content></ng-content>\n\t</div>\n\t<div class=\"ng-doc-playground-properties\">\n\t\t<div class=\"ng-doc-playground-header\">\n\t\t\t<h4 ng-doc-text>Playground</h4>\n\t\t\t<button ng-doc-button color=\"red\" (click)=\"resetForm.emit()\">Reset</button>\n\t\t</div>\n\t\t<div class=\"ng-doc-playground-setting\">\n\t\t\t<ng-doc-checkbox [(ngModel)]=\"recreateDemo\" (ngModelChange)=\"recreateDemoChange.emit($event)\">\n\t\t\t\t<span\n\t\t\t\t\tng-doc-text\n\t\t\t\t\t[ngDocTooltip]=\"'Recreates demo everytime\\none of the input has changed'\"\n\t\t\t\t\t[positions]=\"['bottom-right', 'left-center']\"\n\t\t\t\t>\n\t\t\t\t\tRecreate\n\t\t\t\t\t<ng-doc-icon icon=\"info\" ngDocTextRight></ng-doc-icon>\n\t\t\t\t</span>\n\t\t\t</ng-doc-checkbox>\n\t\t</div>\n\t\t<div class=\"ng-doc-playground-divider\"></div>\n\t\t<ng-container *ngIf=\"propertyControls.length\">\n\t\t\t<h5 class=\"ng-doc-title\" ng-doc-text>Settings</h5>\n\t\t\t<ng-doc-playground-property\n\t\t\t\t*ngFor=\"let propertyControl of propertyControls\"\n\t\t\t\t[name]=\"propertyControl.property.inputName\"\n\t\t\t\t[property]=\"propertyControl.property\"\n\t\t\t\t[typeControl]=\"propertyControl.typeControl\"\n\t\t\t\t[control]=\"getFormControl | bind: this | execute: 'properties': propertyControl.propertyName\"\n\t\t\t>\n\t\t\t</ng-doc-playground-property>\n\t\t</ng-container>\n\n\t\t<ng-container *ngIf=\"(dynamicContent | keyvalue)?.length\">\n\t\t\t<h5 class=\"ng-doc-title\" ng-doc-text>Content</h5>\n\t\t\t<ng-doc-playground-property\n\t\t\t\t*ngFor=\"let content of dynamicContent | keyvalue\"\n\t\t\t\t[name]=\"content.value.label\"\n\t\t\t\t[property]=\"content.value\"\n\t\t\t\t[typeControl]=\"contentTypeControl\"\n\t\t\t\t[control]=\"getFormControl | bind: this | execute: 'content': content.key\"\n\t\t\t>\n\t\t\t</ng-doc-playground-property>\n\t\t</ng-container>\n\t</div>\n</div>\n", styles: [":host .ng-doc-playground-properties-wrapper{position:relative;display:flex}:host .ng-doc-playground-properties-wrapper.vertical{flex-direction:column}:host .ng-doc-playground-properties-wrapper.vertical .ng-doc-playground-demos{margin-right:0;margin-bottom:calc(var(--ng-doc-base-gutter) * 2)}:host .ng-doc-playground-properties-wrapper.vertical .ng-doc-playground-properties{width:100%}:host .ng-doc-playground-properties-wrapper .ng-doc-playground-demos{display:flex;flex-direction:column;width:100%;overflow:hidden;margin-right:calc(var(--ng-doc-base-gutter) * 2)}:host .ng-doc-playground-properties-wrapper .ng-doc-playground-properties{flex-shrink:0;width:300px;padding:calc(var(--ng-doc-base-gutter) * 2) calc(var(--ng-doc-base-gutter) * 3);background-color:var(--ng-doc-base-1);border-radius:var(--ng-doc-base-gutter)}:host .ng-doc-playground-properties-wrapper .ng-doc-playground-properties ng-doc-playground-property:not(:last-child){margin-bottom:calc(var(--ng-doc-base-gutter) * 2)}:host .ng-doc-playground-properties-wrapper .ng-doc-playground-properties .ng-doc-playground-controls{display:flex;justify-content:flex-end}:host .ng-doc-playground-properties-wrapper .ng-doc-playground-properties .ng-doc-playground-header{display:flex;align-items:center;justify-content:space-between;height:40px;margin-bottom:calc(var(--ng-doc-base-gutter) * 2)}:host .ng-doc-playground-properties-wrapper .ng-doc-playground-properties .ng-doc-playground-header h4{margin:0}:host .ng-doc-playground-properties-wrapper .ng-doc-playground-properties .ng-doc-playground-setting{display:flex;flex-direction:column}:host .ng-doc-playground-properties-wrapper .ng-doc-title{margin-top:0;margin-bottom:calc(var(--ng-doc-base-gutter) + var(--ng-doc-base-gutter) / 2)}:host .ng-doc-playground-divider{margin:calc(var(--ng-doc-base-gutter) * 2) 0;height:1px;background-color:var(--ng-doc-base-2)}\n"], dependencies: [{ kind: "component", type: NgDocTextComponent, selector: "[ng-doc-text]", inputs: ["size", "color", "align", "absoluteContent"] }, { kind: "component", type: NgDocButtonComponent, selector: "button[ng-doc-button], a[ng-doc-button], button[ng-doc-button-flat], a[ng-doc-button-flat], button[ng-doc-button-text], a[ng-doc-button-text]", inputs: ["size", "color", "rounded"] }, { kind: "component", type: NgDocCheckboxComponent, selector: "ng-doc-checkbox", inputs: ["color"] }, { kind: "ngmodule", type: FormsModule }, { kind: "directive", type: i2.NgControlStatus, selector: "[formControlName],[ngModel],[formControl]" }, { kind: "directive", type: i2.NgModel, selector: "[ngModel]:not([formControlName]):not([formControl])", inputs: ["name", "disabled", "ngModel", "ngModelOptions"], outputs: ["ngModelChange"], exportAs: ["ngModel"] }, { kind: "directive", type: NgDocTooltipDirective, selector: "[ngDocTooltip]", inputs: ["ngDocTooltip", "delay", "displayOrigin", "pointerOrigin", "positions", "canOpen", "panelClass", "minHeight", "maxHeight", "height", "minWidth", "maxWidth", "width"], outputs: ["beforeOpen", "afterOpen", "beforeClose", "afterClose"], exportAs: ["ngDocTooltip"] }, { kind: "component", type: NgDocIconComponent, selector: "ng-doc-icon", inputs: ["icon", "size"] }, { kind: "directive", type: NgDocTextRightDirective, selector: "[ngDocTextRight]" }, { kind: "directive", type: NgIf, selector: "[ngIf]", inputs: ["ngIf", "ngIfThen", "ngIfElse"] }, { kind: "directive", type: NgFor, selector: "[ngFor][ngForOf]", inputs: ["ngForOf", "ngForTrackBy", "ngForTemplate"] }, { kind: "component", type: NgDocPlaygroundPropertyComponent, selector: "ng-doc-playground-property", inputs: ["name", "property", "typeControl", "control"] }, { kind: "pipe", type: AsyncPipe, name: "async" }, { kind: "pipe", type: KeyValuePipe, name: "keyvalue" }, { kind: "pipe", type: NgDocBindPipe, name: "bind" }, { kind: "pipe", type: NgDocExecutePipe, name: "execute" }], changeDetection: i0.ChangeDetectionStrategy.OnPush }); }
264
+ static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "16.0.0", type: NgDocPlaygroundPropertiesComponent, isStandalone: true, selector: "ng-doc-playground-properties", inputs: { form: "form", properties: "properties", dynamicContent: "dynamicContent", defaultValues: "defaultValues", hideSidePanel: "hideSidePanel", recreateDemo: "recreateDemo" }, outputs: { recreateDemoChange: "recreateDemoChange", resetForm: "resetForm" }, usesOnChanges: true, ngImport: i0, template: "<div class=\"ng-doc-playground-properties-wrapper\" [class.vertical]=\"observer | async\" *ngIf=\"defaultValues\">\n\t<div class=\"ng-doc-playground-demos\">\n\t\t<ng-content></ng-content>\n\t</div>\n\t<div class=\"ng-doc-playground-properties\" *ngIf=\"!hideSidePanel\">\n\t\t<div class=\"ng-doc-playground-header\">\n\t\t\t<h4 ng-doc-text>Playground</h4>\n\t\t\t<button ng-doc-button color=\"red\" (click)=\"resetForm.emit()\">Reset</button>\n\t\t</div>\n\t\t<div class=\"ng-doc-playground-setting\">\n\t\t\t<ng-doc-checkbox [(ngModel)]=\"recreateDemo\" (ngModelChange)=\"recreateDemoChange.emit($event)\">\n\t\t\t\t<span\n\t\t\t\t\tng-doc-text\n\t\t\t\t\t[ngDocTooltip]=\"'Recreates demo everytime\\none of the input has changed'\"\n\t\t\t\t\t[positions]=\"['bottom-right', 'left-center']\"\n\t\t\t\t>\n\t\t\t\t\tRecreate\n\t\t\t\t\t<ng-doc-icon icon=\"info\" ngDocTextRight></ng-doc-icon>\n\t\t\t\t</span>\n\t\t\t</ng-doc-checkbox>\n\t\t</div>\n\t\t<div class=\"ng-doc-playground-divider\"></div>\n\t\t<ng-container *ngIf=\"propertyControls.length\">\n\t\t\t<h5 class=\"ng-doc-title\" ng-doc-text>Settings</h5>\n\t\t\t<ng-doc-playground-property\n\t\t\t\t*ngFor=\"let propertyControl of propertyControls\"\n\t\t\t\t[name]=\"propertyControl.property.inputName\"\n\t\t\t\t[property]=\"propertyControl.property\"\n\t\t\t\t[typeControl]=\"propertyControl.typeControl\"\n\t\t\t\t[defaultValue]=\"defaultValues[propertyControl.propertyName]\"\n\t\t\t\t[control]=\"getFormControl | bind: this | execute: 'properties': propertyControl.propertyName\"\n\t\t\t>\n\t\t\t</ng-doc-playground-property>\n\t\t</ng-container>\n\n\t\t<ng-container *ngIf=\"(dynamicContent | keyvalue)?.length\">\n\t\t\t<h5 class=\"ng-doc-title\" ng-doc-text>Content</h5>\n\t\t\t<ng-doc-playground-property\n\t\t\t\t*ngFor=\"let content of dynamicContent | keyvalue\"\n\t\t\t\t[name]=\"content.value.label\"\n\t\t\t\t[property]=\"content.value\"\n\t\t\t\t[typeControl]=\"contentTypeControl\"\n\t\t\t\t[control]=\"getFormControl | bind: this | execute: 'content': content.key\"\n\t\t\t>\n\t\t\t</ng-doc-playground-property>\n\t\t</ng-container>\n\t</div>\n</div>\n", styles: [":host .ng-doc-playground-properties-wrapper{position:relative;display:flex;grid-gap:calc(var(--ng-doc-base-gutter) * 2);gap:calc(var(--ng-doc-base-gutter) * 2)}:host .ng-doc-playground-properties-wrapper.vertical{flex-direction:column}:host .ng-doc-playground-properties-wrapper.vertical .ng-doc-playground-demos{margin-right:0;margin-bottom:calc(var(--ng-doc-base-gutter) * 2)}:host .ng-doc-playground-properties-wrapper.vertical .ng-doc-playground-properties{width:100%}:host .ng-doc-playground-properties-wrapper .ng-doc-playground-demos{display:flex;flex-direction:column;width:100%;overflow:hidden}:host .ng-doc-playground-properties-wrapper .ng-doc-playground-properties{flex-shrink:0;width:300px;padding:calc(var(--ng-doc-base-gutter) * 2) calc(var(--ng-doc-base-gutter) * 3);background-color:var(--ng-doc-base-1);border-radius:var(--ng-doc-base-gutter)}:host .ng-doc-playground-properties-wrapper .ng-doc-playground-properties ng-doc-playground-property:not(:last-child){margin-bottom:calc(var(--ng-doc-base-gutter) * 2)}:host .ng-doc-playground-properties-wrapper .ng-doc-playground-properties .ng-doc-playground-controls{display:flex;justify-content:flex-end}:host .ng-doc-playground-properties-wrapper .ng-doc-playground-properties .ng-doc-playground-header{display:flex;align-items:center;justify-content:space-between;height:40px;margin-bottom:calc(var(--ng-doc-base-gutter) * 2)}:host .ng-doc-playground-properties-wrapper .ng-doc-playground-properties .ng-doc-playground-header h4{margin:0}:host .ng-doc-playground-properties-wrapper .ng-doc-playground-properties .ng-doc-playground-setting{display:flex;flex-direction:column}:host .ng-doc-playground-properties-wrapper .ng-doc-title{margin-top:0;margin-bottom:calc(var(--ng-doc-base-gutter) + var(--ng-doc-base-gutter) / 2)}:host .ng-doc-playground-divider{margin:calc(var(--ng-doc-base-gutter) * 2) 0;height:1px;background-color:var(--ng-doc-base-2)}\n"], dependencies: [{ kind: "component", type: NgDocTextComponent, selector: "[ng-doc-text]", inputs: ["size", "color", "align", "absoluteContent"] }, { kind: "component", type: NgDocButtonComponent, selector: "button[ng-doc-button], a[ng-doc-button], button[ng-doc-button-flat], a[ng-doc-button-flat], button[ng-doc-button-text], a[ng-doc-button-text]", inputs: ["size", "color", "rounded"] }, { kind: "component", type: NgDocCheckboxComponent, selector: "ng-doc-checkbox", inputs: ["color"] }, { kind: "ngmodule", type: FormsModule }, { kind: "directive", type: i2.NgControlStatus, selector: "[formControlName],[ngModel],[formControl]" }, { kind: "directive", type: i2.NgModel, selector: "[ngModel]:not([formControlName]):not([formControl])", inputs: ["name", "disabled", "ngModel", "ngModelOptions"], outputs: ["ngModelChange"], exportAs: ["ngModel"] }, { kind: "directive", type: NgDocTooltipDirective, selector: "[ngDocTooltip]", inputs: ["ngDocTooltip", "delay", "displayOrigin", "pointerOrigin", "positions", "canOpen", "panelClass", "minHeight", "maxHeight", "height", "minWidth", "maxWidth", "width"], outputs: ["beforeOpen", "afterOpen", "beforeClose", "afterClose"], exportAs: ["ngDocTooltip"] }, { kind: "component", type: NgDocIconComponent, selector: "ng-doc-icon", inputs: ["icon", "size"] }, { kind: "directive", type: NgDocTextRightDirective, selector: "[ngDocTextRight]" }, { kind: "directive", type: NgIf, selector: "[ngIf]", inputs: ["ngIf", "ngIfThen", "ngIfElse"] }, { kind: "directive", type: NgFor, selector: "[ngFor][ngForOf]", inputs: ["ngForOf", "ngForTrackBy", "ngForTemplate"] }, { kind: "component", type: NgDocPlaygroundPropertyComponent, selector: "ng-doc-playground-property", inputs: ["name", "property", "typeControl", "control", "defaultValue"] }, { kind: "pipe", type: AsyncPipe, name: "async" }, { kind: "pipe", type: KeyValuePipe, name: "keyvalue" }, { kind: "pipe", type: NgDocBindPipe, name: "bind" }, { kind: "pipe", type: NgDocExecutePipe, name: "execute" }], changeDetection: i0.ChangeDetectionStrategy.OnPush }); }
286
265
  }
287
266
  i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "16.0.0", ngImport: i0, type: NgDocPlaygroundPropertiesComponent, decorators: [{
288
267
  type: Component,
@@ -301,13 +280,17 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "16.0.0", ngImpor
301
280
  KeyValuePipe,
302
281
  NgDocBindPipe,
303
282
  NgDocExecutePipe,
304
- ], template: "<div class=\"ng-doc-playground-properties-wrapper\" [class.vertical]=\"observer | async\">\n\t<div class=\"ng-doc-playground-demos\">\n\t\t<ng-content></ng-content>\n\t</div>\n\t<div class=\"ng-doc-playground-properties\">\n\t\t<div class=\"ng-doc-playground-header\">\n\t\t\t<h4 ng-doc-text>Playground</h4>\n\t\t\t<button ng-doc-button color=\"red\" (click)=\"resetForm.emit()\">Reset</button>\n\t\t</div>\n\t\t<div class=\"ng-doc-playground-setting\">\n\t\t\t<ng-doc-checkbox [(ngModel)]=\"recreateDemo\" (ngModelChange)=\"recreateDemoChange.emit($event)\">\n\t\t\t\t<span\n\t\t\t\t\tng-doc-text\n\t\t\t\t\t[ngDocTooltip]=\"'Recreates demo everytime\\none of the input has changed'\"\n\t\t\t\t\t[positions]=\"['bottom-right', 'left-center']\"\n\t\t\t\t>\n\t\t\t\t\tRecreate\n\t\t\t\t\t<ng-doc-icon icon=\"info\" ngDocTextRight></ng-doc-icon>\n\t\t\t\t</span>\n\t\t\t</ng-doc-checkbox>\n\t\t</div>\n\t\t<div class=\"ng-doc-playground-divider\"></div>\n\t\t<ng-container *ngIf=\"propertyControls.length\">\n\t\t\t<h5 class=\"ng-doc-title\" ng-doc-text>Settings</h5>\n\t\t\t<ng-doc-playground-property\n\t\t\t\t*ngFor=\"let propertyControl of propertyControls\"\n\t\t\t\t[name]=\"propertyControl.property.inputName\"\n\t\t\t\t[property]=\"propertyControl.property\"\n\t\t\t\t[typeControl]=\"propertyControl.typeControl\"\n\t\t\t\t[control]=\"getFormControl | bind: this | execute: 'properties': propertyControl.propertyName\"\n\t\t\t>\n\t\t\t</ng-doc-playground-property>\n\t\t</ng-container>\n\n\t\t<ng-container *ngIf=\"(dynamicContent | keyvalue)?.length\">\n\t\t\t<h5 class=\"ng-doc-title\" ng-doc-text>Content</h5>\n\t\t\t<ng-doc-playground-property\n\t\t\t\t*ngFor=\"let content of dynamicContent | keyvalue\"\n\t\t\t\t[name]=\"content.value.label\"\n\t\t\t\t[property]=\"content.value\"\n\t\t\t\t[typeControl]=\"contentTypeControl\"\n\t\t\t\t[control]=\"getFormControl | bind: this | execute: 'content': content.key\"\n\t\t\t>\n\t\t\t</ng-doc-playground-property>\n\t\t</ng-container>\n\t</div>\n</div>\n", styles: [":host .ng-doc-playground-properties-wrapper{position:relative;display:flex}:host .ng-doc-playground-properties-wrapper.vertical{flex-direction:column}:host .ng-doc-playground-properties-wrapper.vertical .ng-doc-playground-demos{margin-right:0;margin-bottom:calc(var(--ng-doc-base-gutter) * 2)}:host .ng-doc-playground-properties-wrapper.vertical .ng-doc-playground-properties{width:100%}:host .ng-doc-playground-properties-wrapper .ng-doc-playground-demos{display:flex;flex-direction:column;width:100%;overflow:hidden;margin-right:calc(var(--ng-doc-base-gutter) * 2)}:host .ng-doc-playground-properties-wrapper .ng-doc-playground-properties{flex-shrink:0;width:300px;padding:calc(var(--ng-doc-base-gutter) * 2) calc(var(--ng-doc-base-gutter) * 3);background-color:var(--ng-doc-base-1);border-radius:var(--ng-doc-base-gutter)}:host .ng-doc-playground-properties-wrapper .ng-doc-playground-properties ng-doc-playground-property:not(:last-child){margin-bottom:calc(var(--ng-doc-base-gutter) * 2)}:host .ng-doc-playground-properties-wrapper .ng-doc-playground-properties .ng-doc-playground-controls{display:flex;justify-content:flex-end}:host .ng-doc-playground-properties-wrapper .ng-doc-playground-properties .ng-doc-playground-header{display:flex;align-items:center;justify-content:space-between;height:40px;margin-bottom:calc(var(--ng-doc-base-gutter) * 2)}:host .ng-doc-playground-properties-wrapper .ng-doc-playground-properties .ng-doc-playground-header h4{margin:0}:host .ng-doc-playground-properties-wrapper .ng-doc-playground-properties .ng-doc-playground-setting{display:flex;flex-direction:column}:host .ng-doc-playground-properties-wrapper .ng-doc-title{margin-top:0;margin-bottom:calc(var(--ng-doc-base-gutter) + var(--ng-doc-base-gutter) / 2)}:host .ng-doc-playground-divider{margin:calc(var(--ng-doc-base-gutter) * 2) 0;height:1px;background-color:var(--ng-doc-base-2)}\n"] }]
283
+ ], template: "<div class=\"ng-doc-playground-properties-wrapper\" [class.vertical]=\"observer | async\" *ngIf=\"defaultValues\">\n\t<div class=\"ng-doc-playground-demos\">\n\t\t<ng-content></ng-content>\n\t</div>\n\t<div class=\"ng-doc-playground-properties\" *ngIf=\"!hideSidePanel\">\n\t\t<div class=\"ng-doc-playground-header\">\n\t\t\t<h4 ng-doc-text>Playground</h4>\n\t\t\t<button ng-doc-button color=\"red\" (click)=\"resetForm.emit()\">Reset</button>\n\t\t</div>\n\t\t<div class=\"ng-doc-playground-setting\">\n\t\t\t<ng-doc-checkbox [(ngModel)]=\"recreateDemo\" (ngModelChange)=\"recreateDemoChange.emit($event)\">\n\t\t\t\t<span\n\t\t\t\t\tng-doc-text\n\t\t\t\t\t[ngDocTooltip]=\"'Recreates demo everytime\\none of the input has changed'\"\n\t\t\t\t\t[positions]=\"['bottom-right', 'left-center']\"\n\t\t\t\t>\n\t\t\t\t\tRecreate\n\t\t\t\t\t<ng-doc-icon icon=\"info\" ngDocTextRight></ng-doc-icon>\n\t\t\t\t</span>\n\t\t\t</ng-doc-checkbox>\n\t\t</div>\n\t\t<div class=\"ng-doc-playground-divider\"></div>\n\t\t<ng-container *ngIf=\"propertyControls.length\">\n\t\t\t<h5 class=\"ng-doc-title\" ng-doc-text>Settings</h5>\n\t\t\t<ng-doc-playground-property\n\t\t\t\t*ngFor=\"let propertyControl of propertyControls\"\n\t\t\t\t[name]=\"propertyControl.property.inputName\"\n\t\t\t\t[property]=\"propertyControl.property\"\n\t\t\t\t[typeControl]=\"propertyControl.typeControl\"\n\t\t\t\t[defaultValue]=\"defaultValues[propertyControl.propertyName]\"\n\t\t\t\t[control]=\"getFormControl | bind: this | execute: 'properties': propertyControl.propertyName\"\n\t\t\t>\n\t\t\t</ng-doc-playground-property>\n\t\t</ng-container>\n\n\t\t<ng-container *ngIf=\"(dynamicContent | keyvalue)?.length\">\n\t\t\t<h5 class=\"ng-doc-title\" ng-doc-text>Content</h5>\n\t\t\t<ng-doc-playground-property\n\t\t\t\t*ngFor=\"let content of dynamicContent | keyvalue\"\n\t\t\t\t[name]=\"content.value.label\"\n\t\t\t\t[property]=\"content.value\"\n\t\t\t\t[typeControl]=\"contentTypeControl\"\n\t\t\t\t[control]=\"getFormControl | bind: this | execute: 'content': content.key\"\n\t\t\t>\n\t\t\t</ng-doc-playground-property>\n\t\t</ng-container>\n\t</div>\n</div>\n", styles: [":host .ng-doc-playground-properties-wrapper{position:relative;display:flex;grid-gap:calc(var(--ng-doc-base-gutter) * 2);gap:calc(var(--ng-doc-base-gutter) * 2)}:host .ng-doc-playground-properties-wrapper.vertical{flex-direction:column}:host .ng-doc-playground-properties-wrapper.vertical .ng-doc-playground-demos{margin-right:0;margin-bottom:calc(var(--ng-doc-base-gutter) * 2)}:host .ng-doc-playground-properties-wrapper.vertical .ng-doc-playground-properties{width:100%}:host .ng-doc-playground-properties-wrapper .ng-doc-playground-demos{display:flex;flex-direction:column;width:100%;overflow:hidden}:host .ng-doc-playground-properties-wrapper .ng-doc-playground-properties{flex-shrink:0;width:300px;padding:calc(var(--ng-doc-base-gutter) * 2) calc(var(--ng-doc-base-gutter) * 3);background-color:var(--ng-doc-base-1);border-radius:var(--ng-doc-base-gutter)}:host .ng-doc-playground-properties-wrapper .ng-doc-playground-properties ng-doc-playground-property:not(:last-child){margin-bottom:calc(var(--ng-doc-base-gutter) * 2)}:host .ng-doc-playground-properties-wrapper .ng-doc-playground-properties .ng-doc-playground-controls{display:flex;justify-content:flex-end}:host .ng-doc-playground-properties-wrapper .ng-doc-playground-properties .ng-doc-playground-header{display:flex;align-items:center;justify-content:space-between;height:40px;margin-bottom:calc(var(--ng-doc-base-gutter) * 2)}:host .ng-doc-playground-properties-wrapper .ng-doc-playground-properties .ng-doc-playground-header h4{margin:0}:host .ng-doc-playground-properties-wrapper .ng-doc-playground-properties .ng-doc-playground-setting{display:flex;flex-direction:column}:host .ng-doc-playground-properties-wrapper .ng-doc-title{margin-top:0;margin-bottom:calc(var(--ng-doc-base-gutter) + var(--ng-doc-base-gutter) / 2)}:host .ng-doc-playground-divider{margin:calc(var(--ng-doc-base-gutter) * 2) 0;height:1px;background-color:var(--ng-doc-base-2)}\n"] }]
305
284
  }], ctorParameters: function () { return [{ type: i1.BreakpointObserver }, { type: i0.Injector }]; }, propDecorators: { form: [{
306
285
  type: Input
307
286
  }], properties: [{
308
287
  type: Input
309
288
  }], dynamicContent: [{
310
289
  type: Input
290
+ }], defaultValues: [{
291
+ type: Input
292
+ }], hideSidePanel: [{
293
+ type: Input
311
294
  }], recreateDemo: [{
312
295
  type: Input
313
296
  }], recreateDemoChange: [{
@@ -317,32 +300,42 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "16.0.0", ngImpor
317
300
  }] } });
318
301
 
319
302
  class NgDocPlaygroundComponent {
320
- constructor(rootPage, formBuilder) {
303
+ constructor(rootPage, formBuilder, changeDetectorRef) {
321
304
  this.rootPage = rootPage;
322
305
  this.formBuilder = formBuilder;
306
+ this.changeDetectorRef = changeDetectorRef;
323
307
  this.id = '';
324
308
  this.pipeName = '';
325
309
  this.selectors = [];
310
+ this.options = {};
326
311
  this.recreateDemo = false;
327
312
  }
328
313
  ngOnInit() {
314
+ // Join configuration with options
315
+ this.configuration = Object.assign({}, this.rootPage.page?.playgrounds?.[this.id], this.options);
316
+ }
317
+ ngAfterViewInit() {
329
318
  const propertiesForm = this.formBuilder.group(this.getPropertiesFormValues());
330
319
  const contentForm = this.formBuilder.group(this.getContentFormValues());
331
320
  this.formGroup = this.formBuilder.group({
332
321
  properties: propertiesForm,
333
322
  content: contentForm,
334
323
  });
335
- }
336
- get configuration() {
337
- return this.rootPage.page?.playgrounds?.[this.id];
324
+ // `patchValue` is needed to set `undefined` values, otherwise they will be ignored by the Angular form
325
+ this.formGroup.patchValue({
326
+ properties: Object.assign({}, this.getPropertiesFormValues(), this.configuration.inputs),
327
+ content: this.getContentFormValues(),
328
+ });
329
+ this.changeDetectorRef.detectChanges();
338
330
  }
339
331
  getPropertiesFormValues() {
340
- return objectKeys(this.properties ?? {}).reduce((controls, key) => {
332
+ const formValues = objectKeys(this.properties ?? {}).reduce((controls, key) => {
341
333
  if (this.properties) {
342
- controls[key] = extractValue(this.properties[key]?.default ?? 'undefined');
334
+ controls[key] = this.defaultValues ? this.defaultValues[key] : undefined;
343
335
  }
344
336
  return controls;
345
337
  }, {});
338
+ return Object.assign({}, formValues, this.configuration.defaults);
346
339
  }
347
340
  getContentFormValues() {
348
341
  return objectKeys(this.configuration?.content ?? {}).reduce((controls, key) => {
@@ -354,18 +347,82 @@ class NgDocPlaygroundComponent {
354
347
  return {};
355
348
  }
356
349
  resetForm() {
357
- this.formGroup?.reset({
350
+ this.formGroup?.patchValue({
358
351
  properties: this.getPropertiesFormValues(),
359
352
  content: this.getContentFormValues(),
360
353
  });
361
354
  }
362
- static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "16.0.0", ngImport: i0, type: NgDocPlaygroundComponent, deps: [{ token: i1$1.NgDocRootPage }, { token: i2.FormBuilder }], target: i0.ɵɵFactoryTarget.Component }); }
363
- static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "16.0.0", type: NgDocPlaygroundComponent, isStandalone: true, selector: "ng-doc-playground", ngImport: i0, template: "<ng-container *ngIf=\"configuration\">\n\t<ng-doc-playground-properties\n\t\t[form]=\"formGroup\"\n\t\t[properties]=\"properties\"\n\t\t[dynamicContent]=\"configuration.content\"\n\t\t[(recreateDemo)]=\"recreateDemo\"\n\t\t(resetForm)=\"resetForm()\"\n\t>\n\t\t<ng-doc-playground-demo\n\t\t\t*ngFor=\"let selector of configuration.selectors ?? selectors | asArray\"\n\t\t\t[id]=\"id\"\n\t\t\t[selector]=\"selector\"\n\t\t\t[properties]=\"properties\"\n\t\t\t[configuration]=\"configuration\"\n\t\t\t[recreateDemo]=\"recreateDemo\"\n\t\t\t[form]=\"formGroup\"\n\t\t>\n\t\t</ng-doc-playground-demo>\n\n\t\t<ng-doc-playground-demo\n\t\t\t*ngIf=\"pipeName\"\n\t\t\t[id]=\"id\"\n\t\t\t[pipeName]=\"pipeName\"\n\t\t\t[properties]=\"properties\"\n\t\t\t[configuration]=\"configuration\"\n\t\t\t[recreateDemo]=\"recreateDemo\"\n\t\t\t[form]=\"formGroup\"\n\t\t>\n\t\t</ng-doc-playground-demo>\n\t</ng-doc-playground-properties>\n</ng-container>\n", styles: [":host{display:block}\n"], dependencies: [{ kind: "directive", type: NgIf, selector: "[ngIf]", inputs: ["ngIf", "ngIfThen", "ngIfElse"] }, { kind: "component", type: NgDocPlaygroundPropertiesComponent, selector: "ng-doc-playground-properties", inputs: ["form", "properties", "dynamicContent", "recreateDemo"], outputs: ["recreateDemoChange", "resetForm"] }, { kind: "directive", type: NgFor, selector: "[ngFor][ngForOf]", inputs: ["ngForOf", "ngForTrackBy", "ngForTemplate"] }, { kind: "component", type: NgDocPlaygroundDemoComponent, selector: "ng-doc-playground-demo", inputs: ["id", "pipeName", "selector", "configuration", "properties", "recreateDemo", "form"] }, { kind: "pipe", type: NgDocAsArrayPipe, name: "asArray" }], changeDetection: i0.ChangeDetectionStrategy.OnPush }); }
355
+ static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "16.0.0", ngImport: i0, type: NgDocPlaygroundComponent, deps: [{ token: i1$1.NgDocRootPage }, { token: i2.FormBuilder }, { token: i0.ChangeDetectorRef }], target: i0.ɵɵFactoryTarget.Component }); }
356
+ static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "16.0.0", type: NgDocPlaygroundComponent, isStandalone: true, selector: "ng-doc-playground", inputs: { id: "id", pipeName: "pipeName", selectors: "selectors", properties: "properties", options: "options" }, ngImport: i0, template: "<ng-container *ngIf=\"configuration\">\n\t<ng-doc-playground-properties\n\t\t[form]=\"formGroup\"\n\t\t[properties]=\"properties\"\n\t\t[dynamicContent]=\"configuration.content\"\n\t\t[hideSidePanel]=\"configuration.hideSidePanel ?? false\"\n\t\t[defaultValues]=\"defaultValues\"\n\t\t[(recreateDemo)]=\"recreateDemo\"\n\t\t(resetForm)=\"resetForm()\"\n\t>\n\t\t<ng-doc-playground-demo\n\t\t\t*ngFor=\"let selector of configuration.selectors ?? selectors | asArray\"\n\t\t\t[id]=\"id\"\n\t\t\t[selector]=\"selector\"\n\t\t\t[properties]=\"properties\"\n\t\t\t[configuration]=\"configuration\"\n\t\t\t[recreateDemo]=\"recreateDemo\"\n\t\t\t[form]=\"formGroup\"\n\t\t\t[expanded]=\"configuration.expanded ?? false\"\n\t\t>\n\t\t</ng-doc-playground-demo>\n\n\t\t<ng-doc-playground-demo\n\t\t\t*ngIf=\"pipeName\"\n\t\t\t[id]=\"id\"\n\t\t\t[pipeName]=\"pipeName\"\n\t\t\t[properties]=\"properties\"\n\t\t\t[configuration]=\"configuration\"\n\t\t\t[recreateDemo]=\"recreateDemo\"\n\t\t\t[form]=\"formGroup\"\n\t\t>\n\t\t</ng-doc-playground-demo>\n\t</ng-doc-playground-properties>\n</ng-container>\n", styles: [":host{display:block}\n"], dependencies: [{ kind: "directive", type: NgIf, selector: "[ngIf]", inputs: ["ngIf", "ngIfThen", "ngIfElse"] }, { kind: "component", type: NgDocPlaygroundPropertiesComponent, selector: "ng-doc-playground-properties", inputs: ["form", "properties", "dynamicContent", "defaultValues", "hideSidePanel", "recreateDemo"], outputs: ["recreateDemoChange", "resetForm"] }, { kind: "directive", type: NgFor, selector: "[ngFor][ngForOf]", inputs: ["ngForOf", "ngForTrackBy", "ngForTemplate"] }, { kind: "component", type: NgDocPlaygroundDemoComponent, selector: "ng-doc-playground-demo", inputs: ["id", "pipeName", "selector", "configuration", "properties", "recreateDemo", "form", "expanded"] }, { kind: "pipe", type: NgDocAsArrayPipe, name: "asArray" }], changeDetection: i0.ChangeDetectionStrategy.OnPush }); }
364
357
  }
365
358
  i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "16.0.0", ngImport: i0, type: NgDocPlaygroundComponent, decorators: [{
366
359
  type: Component,
367
- args: [{ selector: 'ng-doc-playground', changeDetection: ChangeDetectionStrategy.OnPush, standalone: true, imports: [NgIf, NgDocPlaygroundPropertiesComponent, NgFor, NgDocPlaygroundDemoComponent, NgDocAsArrayPipe], template: "<ng-container *ngIf=\"configuration\">\n\t<ng-doc-playground-properties\n\t\t[form]=\"formGroup\"\n\t\t[properties]=\"properties\"\n\t\t[dynamicContent]=\"configuration.content\"\n\t\t[(recreateDemo)]=\"recreateDemo\"\n\t\t(resetForm)=\"resetForm()\"\n\t>\n\t\t<ng-doc-playground-demo\n\t\t\t*ngFor=\"let selector of configuration.selectors ?? selectors | asArray\"\n\t\t\t[id]=\"id\"\n\t\t\t[selector]=\"selector\"\n\t\t\t[properties]=\"properties\"\n\t\t\t[configuration]=\"configuration\"\n\t\t\t[recreateDemo]=\"recreateDemo\"\n\t\t\t[form]=\"formGroup\"\n\t\t>\n\t\t</ng-doc-playground-demo>\n\n\t\t<ng-doc-playground-demo\n\t\t\t*ngIf=\"pipeName\"\n\t\t\t[id]=\"id\"\n\t\t\t[pipeName]=\"pipeName\"\n\t\t\t[properties]=\"properties\"\n\t\t\t[configuration]=\"configuration\"\n\t\t\t[recreateDemo]=\"recreateDemo\"\n\t\t\t[form]=\"formGroup\"\n\t\t>\n\t\t</ng-doc-playground-demo>\n\t</ng-doc-playground-properties>\n</ng-container>\n", styles: [":host{display:block}\n"] }]
368
- }], ctorParameters: function () { return [{ type: i1$1.NgDocRootPage }, { type: i2.FormBuilder }]; } });
360
+ args: [{ selector: 'ng-doc-playground', changeDetection: ChangeDetectionStrategy.OnPush, standalone: true, imports: [NgIf, NgDocPlaygroundPropertiesComponent, NgFor, NgDocPlaygroundDemoComponent, NgDocAsArrayPipe], template: "<ng-container *ngIf=\"configuration\">\n\t<ng-doc-playground-properties\n\t\t[form]=\"formGroup\"\n\t\t[properties]=\"properties\"\n\t\t[dynamicContent]=\"configuration.content\"\n\t\t[hideSidePanel]=\"configuration.hideSidePanel ?? false\"\n\t\t[defaultValues]=\"defaultValues\"\n\t\t[(recreateDemo)]=\"recreateDemo\"\n\t\t(resetForm)=\"resetForm()\"\n\t>\n\t\t<ng-doc-playground-demo\n\t\t\t*ngFor=\"let selector of configuration.selectors ?? selectors | asArray\"\n\t\t\t[id]=\"id\"\n\t\t\t[selector]=\"selector\"\n\t\t\t[properties]=\"properties\"\n\t\t\t[configuration]=\"configuration\"\n\t\t\t[recreateDemo]=\"recreateDemo\"\n\t\t\t[form]=\"formGroup\"\n\t\t\t[expanded]=\"configuration.expanded ?? false\"\n\t\t>\n\t\t</ng-doc-playground-demo>\n\n\t\t<ng-doc-playground-demo\n\t\t\t*ngIf=\"pipeName\"\n\t\t\t[id]=\"id\"\n\t\t\t[pipeName]=\"pipeName\"\n\t\t\t[properties]=\"properties\"\n\t\t\t[configuration]=\"configuration\"\n\t\t\t[recreateDemo]=\"recreateDemo\"\n\t\t\t[form]=\"formGroup\"\n\t\t>\n\t\t</ng-doc-playground-demo>\n\t</ng-doc-playground-properties>\n</ng-container>\n", styles: [":host{display:block}\n"] }]
361
+ }], ctorParameters: function () { return [{ type: i1$1.NgDocRootPage }, { type: i2.FormBuilder }, { type: i0.ChangeDetectorRef }]; }, propDecorators: { id: [{
362
+ type: Input,
363
+ args: [{ required: true }]
364
+ }], pipeName: [{
365
+ type: Input
366
+ }], selectors: [{
367
+ type: Input
368
+ }], properties: [{
369
+ type: Input
370
+ }], options: [{
371
+ type: Input
372
+ }] } });
373
+
374
+ /**
375
+ * Base class for playgrounds components.
376
+ */
377
+ class NgDocBasePlayground {
378
+ constructor() {
379
+ this.properties = {};
380
+ this.actionData = {};
381
+ this.content = {};
382
+ this.defaultValues = {};
383
+ this.playgroundContainer = inject(NgDocPlaygroundComponent);
384
+ }
385
+ static { this.selector = 'unknown'; }
386
+ ngOnInit() {
387
+ /*
388
+ * Extract default values from playground properties. We do this in `ngOnInit` because in this case
389
+ * input values provided from the template are not initialized yet, and we can read default values instead.
390
+ */
391
+ if (this.playground) {
392
+ this.defaultValues = Object.keys(this.playground).reduce((values, key) => {
393
+ if (this.playground) {
394
+ // eslint-disable-next-line @typescript-eslint/ban-ts-comment
395
+ // @ts-ignore
396
+ values[key] = this.playground[key];
397
+ }
398
+ return values;
399
+ }, {});
400
+ }
401
+ else if (this.playgroundInstance) {
402
+ this.defaultValues = extractFunctionDefaults(this.playgroundInstance.prototype.transform);
403
+ }
404
+ else {
405
+ throw new Error('Playground is not defined or initialized');
406
+ }
407
+ if (!this.playgroundContainer.defaultValues) {
408
+ this.playgroundContainer.defaultValues = this.defaultValues;
409
+ }
410
+ }
411
+ get data() {
412
+ return Object.assign({}, this.configData, this.actionData);
413
+ }
414
+ static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "16.0.0", ngImport: i0, type: NgDocBasePlayground, deps: [], target: i0.ɵɵFactoryTarget.Directive }); }
415
+ static { this.ɵdir = i0.ɵɵngDeclareDirective({ minVersion: "14.0.0", version: "16.0.0", type: NgDocBasePlayground, inputs: { properties: "properties", actionData: "actionData", content: "content" }, ngImport: i0 }); }
416
+ }
417
+ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "16.0.0", ngImport: i0, type: NgDocBasePlayground, decorators: [{
418
+ type: Directive
419
+ }], propDecorators: { properties: [{
420
+ type: Input
421
+ }], actionData: [{
422
+ type: Input
423
+ }], content: [{
424
+ type: Input
425
+ }] } });
369
426
 
370
427
  /**
371
428
  * Generated bundle index. Do not edit.