@fundamental-ngx/core 0.35.1 → 0.35.2-rc.10

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 (257) hide show
  1. package/action-bar/package.json +1 -1
  2. package/action-sheet/package.json +1 -1
  3. package/alert/package.json +1 -1
  4. package/avatar/package.json +1 -1
  5. package/avatar-group/directives/avatar-group-overflow-button.directive.d.ts +4 -2
  6. package/avatar-group/esm2020/directives/avatar-group-overflow-button.directive.mjs +5 -1
  7. package/avatar-group/fesm2015/fundamental-ngx-core-avatar-group.mjs +4 -0
  8. package/avatar-group/fesm2015/fundamental-ngx-core-avatar-group.mjs.map +1 -1
  9. package/avatar-group/fesm2020/fundamental-ngx-core-avatar-group.mjs +4 -0
  10. package/avatar-group/fesm2020/fundamental-ngx-core-avatar-group.mjs.map +1 -1
  11. package/avatar-group/package.json +1 -1
  12. package/bar/esm2020/bar.component.mjs +2 -2
  13. package/bar/fesm2015/fundamental-ngx-core-bar.mjs +2 -2
  14. package/bar/fesm2020/fundamental-ngx-core-bar.mjs +2 -2
  15. package/bar/package.json +1 -1
  16. package/breadcrumb/package.json +1 -1
  17. package/busy-indicator/package.json +1 -1
  18. package/button/package.json +1 -1
  19. package/calendar/package.json +1 -1
  20. package/card/package.json +1 -1
  21. package/carousel/package.json +1 -1
  22. package/checkbox/package.json +1 -1
  23. package/combobox/package.json +1 -1
  24. package/date-picker/package.json +1 -1
  25. package/datetime/package.json +1 -1
  26. package/datetime-picker/package.json +1 -1
  27. package/dialog/package.json +1 -1
  28. package/dynamic-page/package.json +1 -1
  29. package/dynamic-side-content/package.json +1 -1
  30. package/esm2020/avatar-group/directives/avatar-group-overflow-button.directive.mjs +5 -1
  31. package/esm2020/bar/bar.component.mjs +2 -2
  32. package/esm2020/fixed-card-layout/fixed-card-layout.component.mjs +17 -26
  33. package/esm2020/fundamental-ngx.module.mjs +8 -4
  34. package/esm2020/info-label/info-label.component.mjs +12 -4
  35. package/esm2020/info-label/info-label.module.mjs +5 -4
  36. package/esm2020/input-group/input-group.component.mjs +3 -3
  37. package/esm2020/overflow-layout/directives/overflow-expand.directive.mjs +36 -0
  38. package/esm2020/overflow-layout/directives/overflow-item-container-ref.directive.mjs +46 -0
  39. package/esm2020/overflow-layout/directives/overflow-item-ref.directive.mjs +57 -0
  40. package/esm2020/overflow-layout/directives/overflow-layout-item-container.directive.mjs +26 -0
  41. package/esm2020/overflow-layout/directives/overflow-layout-item.directive.mjs +100 -0
  42. package/esm2020/overflow-layout/directives/overflow-layout-popover-content.directive.mjs +68 -0
  43. package/esm2020/overflow-layout/fundamental-ngx-core-overflow-layout.mjs +5 -0
  44. package/esm2020/overflow-layout/index.mjs +15 -0
  45. package/esm2020/overflow-layout/interfaces/overflow-container.interface.mjs +2 -0
  46. package/esm2020/overflow-layout/interfaces/overflow-expand.interface.mjs +2 -0
  47. package/esm2020/overflow-layout/interfaces/overflow-item-ref.interface.mjs +2 -0
  48. package/esm2020/overflow-layout/interfaces/overflow-item.interface.mjs +2 -0
  49. package/esm2020/overflow-layout/interfaces/overflow-popover-content.interface.mjs +2 -0
  50. package/esm2020/overflow-layout/overflow-layout.component.mjs +300 -0
  51. package/esm2020/overflow-layout/overflow-layout.module.mjs +52 -0
  52. package/esm2020/overflow-layout/tokens/overflow-container.token.mjs +3 -0
  53. package/esm2020/overflow-layout/tokens/overflow-expand.token.mjs +3 -0
  54. package/esm2020/overflow-layout/tokens/overflow-item-ref.token.mjs +3 -0
  55. package/esm2020/overflow-layout/tokens/overflow-item.token.mjs +3 -0
  56. package/esm2020/public_api.mjs +2 -1
  57. package/esm2020/select/select.component.mjs +1 -2
  58. package/esm2020/tabs/tab-panel/tab-panel.component.mjs +8 -3
  59. package/esm2020/theming/theming.service.mjs +1 -1
  60. package/esm2020/wizard/wizard.component.mjs +4 -3
  61. package/esm2020/wizard/wizard.module.mjs +5 -4
  62. package/facets/package.json +1 -1
  63. package/feed-input/package.json +1 -1
  64. package/feed-list-item/package.json +1 -1
  65. package/fesm2015/fundamental-ngx-core-avatar-group.mjs +4 -0
  66. package/fesm2015/fundamental-ngx-core-avatar-group.mjs.map +1 -1
  67. package/fesm2015/fundamental-ngx-core-bar.mjs +2 -2
  68. package/fesm2015/fundamental-ngx-core-fixed-card-layout.mjs +16 -25
  69. package/fesm2015/fundamental-ngx-core-fixed-card-layout.mjs.map +1 -1
  70. package/fesm2015/fundamental-ngx-core-info-label.mjs +15 -6
  71. package/fesm2015/fundamental-ngx-core-info-label.mjs.map +1 -1
  72. package/fesm2015/fundamental-ngx-core-input-group.mjs +2 -2
  73. package/fesm2015/fundamental-ngx-core-input-group.mjs.map +1 -1
  74. package/fesm2015/fundamental-ngx-core-overflow-layout.mjs +672 -0
  75. package/fesm2015/fundamental-ngx-core-overflow-layout.mjs.map +1 -0
  76. package/fesm2015/fundamental-ngx-core-select.mjs +0 -1
  77. package/fesm2015/fundamental-ngx-core-select.mjs.map +1 -1
  78. package/fesm2015/fundamental-ngx-core-tabs.mjs +7 -2
  79. package/fesm2015/fundamental-ngx-core-tabs.mjs.map +1 -1
  80. package/fesm2015/fundamental-ngx-core-theming.mjs.map +1 -1
  81. package/fesm2015/fundamental-ngx-core-wizard.mjs +7 -5
  82. package/fesm2015/fundamental-ngx-core-wizard.mjs.map +1 -1
  83. package/fesm2015/fundamental-ngx-core.mjs +8 -3
  84. package/fesm2015/fundamental-ngx-core.mjs.map +1 -1
  85. package/fesm2020/fundamental-ngx-core-avatar-group.mjs +4 -0
  86. package/fesm2020/fundamental-ngx-core-avatar-group.mjs.map +1 -1
  87. package/fesm2020/fundamental-ngx-core-bar.mjs +2 -2
  88. package/fesm2020/fundamental-ngx-core-fixed-card-layout.mjs +16 -25
  89. package/fesm2020/fundamental-ngx-core-fixed-card-layout.mjs.map +1 -1
  90. package/fesm2020/fundamental-ngx-core-info-label.mjs +15 -6
  91. package/fesm2020/fundamental-ngx-core-info-label.mjs.map +1 -1
  92. package/fesm2020/fundamental-ngx-core-input-group.mjs +2 -2
  93. package/fesm2020/fundamental-ngx-core-input-group.mjs.map +1 -1
  94. package/fesm2020/fundamental-ngx-core-overflow-layout.mjs +660 -0
  95. package/fesm2020/fundamental-ngx-core-overflow-layout.mjs.map +1 -0
  96. package/fesm2020/fundamental-ngx-core-select.mjs +0 -1
  97. package/fesm2020/fundamental-ngx-core-select.mjs.map +1 -1
  98. package/fesm2020/fundamental-ngx-core-tabs.mjs +7 -2
  99. package/fesm2020/fundamental-ngx-core-tabs.mjs.map +1 -1
  100. package/fesm2020/fundamental-ngx-core-theming.mjs.map +1 -1
  101. package/fesm2020/fundamental-ngx-core-wizard.mjs +7 -5
  102. package/fesm2020/fundamental-ngx-core-wizard.mjs.map +1 -1
  103. package/fesm2020/fundamental-ngx-core.mjs +8 -3
  104. package/fesm2020/fundamental-ngx-core.mjs.map +1 -1
  105. package/file-uploader/package.json +1 -1
  106. package/fixed-card-layout/esm2020/fixed-card-layout.component.mjs +17 -26
  107. package/fixed-card-layout/fesm2015/fundamental-ngx-core-fixed-card-layout.mjs +16 -25
  108. package/fixed-card-layout/fesm2015/fundamental-ngx-core-fixed-card-layout.mjs.map +1 -1
  109. package/fixed-card-layout/fesm2020/fundamental-ngx-core-fixed-card-layout.mjs +16 -25
  110. package/fixed-card-layout/fesm2020/fundamental-ngx-core-fixed-card-layout.mjs.map +1 -1
  111. package/fixed-card-layout/fixed-card-layout.component.d.ts +4 -6
  112. package/fixed-card-layout/package.json +1 -1
  113. package/flexible-column-layout/package.json +1 -1
  114. package/form/package.json +1 -1
  115. package/formatted-text/package.json +1 -1
  116. package/fundamental-ngx.module.d.ts +2 -1
  117. package/grid-list/package.json +1 -1
  118. package/icon/package.json +1 -1
  119. package/illustrated-message/package.json +1 -1
  120. package/infinite-scroll/package.json +1 -1
  121. package/info-label/esm2020/info-label.component.mjs +12 -4
  122. package/info-label/esm2020/info-label.module.mjs +5 -4
  123. package/info-label/fesm2015/fundamental-ngx-core-info-label.mjs +15 -6
  124. package/info-label/fesm2015/fundamental-ngx-core-info-label.mjs.map +1 -1
  125. package/info-label/fesm2020/fundamental-ngx-core-info-label.mjs +15 -6
  126. package/info-label/fesm2020/fundamental-ngx-core-info-label.mjs.map +1 -1
  127. package/info-label/info-label.component.d.ts +11 -3
  128. package/info-label/info-label.module.d.ts +2 -1
  129. package/info-label/package.json +1 -1
  130. package/inline-help/package.json +1 -1
  131. package/input-group/esm2020/input-group.component.mjs +3 -3
  132. package/input-group/fesm2015/fundamental-ngx-core-input-group.mjs +2 -2
  133. package/input-group/fesm2015/fundamental-ngx-core-input-group.mjs.map +1 -1
  134. package/input-group/fesm2020/fundamental-ngx-core-input-group.mjs +2 -2
  135. package/input-group/fesm2020/fundamental-ngx-core-input-group.mjs.map +1 -1
  136. package/input-group/package.json +1 -1
  137. package/layout-grid/package.json +1 -1
  138. package/layout-panel/package.json +1 -1
  139. package/link/package.json +1 -1
  140. package/list/package.json +1 -1
  141. package/menu/package.json +1 -1
  142. package/message-box/package.json +1 -1
  143. package/message-strip/package.json +1 -1
  144. package/message-toast/package.json +1 -1
  145. package/micro-process-flow/package.json +1 -1
  146. package/mobile-mode/package.json +1 -1
  147. package/multi-input/package.json +1 -1
  148. package/nested-list/package.json +1 -1
  149. package/notification/package.json +1 -1
  150. package/object-identifier/package.json +1 -1
  151. package/object-marker/package.json +1 -1
  152. package/object-number/package.json +1 -1
  153. package/object-status/package.json +1 -1
  154. package/overflow-layout/README.md +7 -0
  155. package/overflow-layout/directives/overflow-expand.directive.d.ts +15 -0
  156. package/overflow-layout/directives/overflow-item-container-ref.directive.d.ts +25 -0
  157. package/overflow-layout/directives/overflow-item-ref.directive.d.ts +42 -0
  158. package/overflow-layout/directives/overflow-layout-item-container.directive.d.ts +16 -0
  159. package/overflow-layout/directives/overflow-layout-item.directive.d.ts +38 -0
  160. package/overflow-layout/directives/overflow-layout-popover-content.directive.d.ts +31 -0
  161. package/overflow-layout/esm2020/directives/overflow-expand.directive.mjs +36 -0
  162. package/overflow-layout/esm2020/directives/overflow-item-container-ref.directive.mjs +46 -0
  163. package/overflow-layout/esm2020/directives/overflow-item-ref.directive.mjs +57 -0
  164. package/overflow-layout/esm2020/directives/overflow-layout-item-container.directive.mjs +26 -0
  165. package/overflow-layout/esm2020/directives/overflow-layout-item.directive.mjs +100 -0
  166. package/overflow-layout/esm2020/directives/overflow-layout-popover-content.directive.mjs +68 -0
  167. package/overflow-layout/esm2020/fundamental-ngx-core-overflow-layout.mjs +5 -0
  168. package/overflow-layout/esm2020/index.mjs +15 -0
  169. package/overflow-layout/esm2020/interfaces/overflow-container.interface.mjs +2 -0
  170. package/overflow-layout/esm2020/interfaces/overflow-expand.interface.mjs +2 -0
  171. package/overflow-layout/esm2020/interfaces/overflow-item-ref.interface.mjs +2 -0
  172. package/overflow-layout/esm2020/interfaces/overflow-item.interface.mjs +2 -0
  173. package/overflow-layout/esm2020/interfaces/overflow-popover-content.interface.mjs +2 -0
  174. package/overflow-layout/esm2020/overflow-layout.component.mjs +300 -0
  175. package/overflow-layout/esm2020/overflow-layout.module.mjs +52 -0
  176. package/overflow-layout/esm2020/tokens/overflow-container.token.mjs +3 -0
  177. package/overflow-layout/esm2020/tokens/overflow-expand.token.mjs +3 -0
  178. package/overflow-layout/esm2020/tokens/overflow-item-ref.token.mjs +3 -0
  179. package/overflow-layout/esm2020/tokens/overflow-item.token.mjs +3 -0
  180. package/overflow-layout/fesm2015/fundamental-ngx-core-overflow-layout.mjs +672 -0
  181. package/overflow-layout/fesm2015/fundamental-ngx-core-overflow-layout.mjs.map +1 -0
  182. package/overflow-layout/fesm2020/fundamental-ngx-core-overflow-layout.mjs +660 -0
  183. package/overflow-layout/fesm2020/fundamental-ngx-core-overflow-layout.mjs.map +1 -0
  184. package/overflow-layout/fundamental-ngx-core-overflow-layout.d.ts +5 -0
  185. package/overflow-layout/index.d.ts +14 -0
  186. package/overflow-layout/interfaces/overflow-container.interface.d.ts +4 -0
  187. package/overflow-layout/interfaces/overflow-expand.interface.d.ts +11 -0
  188. package/overflow-layout/interfaces/overflow-item-ref.interface.d.ts +38 -0
  189. package/overflow-layout/interfaces/overflow-item.interface.d.ts +20 -0
  190. package/overflow-layout/interfaces/overflow-popover-content.interface.d.ts +11 -0
  191. package/overflow-layout/overflow-layout.component.d.ts +131 -0
  192. package/overflow-layout/overflow-layout.module.d.ts +16 -0
  193. package/overflow-layout/package.json +53 -0
  194. package/overflow-layout/tokens/overflow-container.token.d.ts +3 -0
  195. package/overflow-layout/tokens/overflow-expand.token.d.ts +3 -0
  196. package/overflow-layout/tokens/overflow-item-ref.token.d.ts +3 -0
  197. package/overflow-layout/tokens/overflow-item.token.d.ts +3 -0
  198. package/package.json +9 -1
  199. package/pagination/package.json +1 -1
  200. package/panel/package.json +1 -1
  201. package/popover/package.json +1 -1
  202. package/product-switch/package.json +1 -1
  203. package/progress-indicator/package.json +1 -1
  204. package/public_api.d.ts +1 -0
  205. package/quick-view/package.json +1 -1
  206. package/radio/package.json +1 -1
  207. package/rating-indicator/package.json +1 -1
  208. package/resizable-card-layout/package.json +1 -1
  209. package/scroll-spy/package.json +1 -1
  210. package/scrollbar/package.json +1 -1
  211. package/segmented-button/package.json +1 -1
  212. package/select/esm2020/select.component.mjs +1 -2
  213. package/select/fesm2015/fundamental-ngx-core-select.mjs +0 -1
  214. package/select/fesm2015/fundamental-ngx-core-select.mjs.map +1 -1
  215. package/select/fesm2020/fundamental-ngx-core-select.mjs +0 -1
  216. package/select/fesm2020/fundamental-ngx-core-select.mjs.map +1 -1
  217. package/select/package.json +1 -1
  218. package/shared/package.json +1 -1
  219. package/shellbar/package.json +1 -1
  220. package/side-navigation/package.json +1 -1
  221. package/slider/package.json +1 -1
  222. package/split-button/package.json +1 -1
  223. package/splitter/package.json +1 -1
  224. package/status-indicator/package.json +1 -1
  225. package/step-input/package.json +1 -1
  226. package/switch/package.json +1 -1
  227. package/table/package.json +1 -1
  228. package/tabs/esm2020/tab-panel/tab-panel.component.mjs +8 -3
  229. package/tabs/fesm2015/fundamental-ngx-core-tabs.mjs +7 -2
  230. package/tabs/fesm2015/fundamental-ngx-core-tabs.mjs.map +1 -1
  231. package/tabs/fesm2020/fundamental-ngx-core-tabs.mjs +7 -2
  232. package/tabs/fesm2020/fundamental-ngx-core-tabs.mjs.map +1 -1
  233. package/tabs/package.json +1 -1
  234. package/text/package.json +1 -1
  235. package/theming/esm2020/theming.service.mjs +1 -1
  236. package/theming/fesm2015/fundamental-ngx-core-theming.mjs.map +1 -1
  237. package/theming/fesm2020/fundamental-ngx-core-theming.mjs.map +1 -1
  238. package/theming/package.json +1 -1
  239. package/tile/package.json +1 -1
  240. package/time/package.json +1 -1
  241. package/time-picker/package.json +1 -1
  242. package/timeline/package.json +1 -1
  243. package/title/package.json +1 -1
  244. package/token/package.json +1 -1
  245. package/toolbar/package.json +1 -1
  246. package/tree/package.json +1 -1
  247. package/upload-collection/package.json +1 -1
  248. package/utils/package.json +1 -1
  249. package/vertical-navigation/package.json +1 -1
  250. package/wizard/esm2020/wizard.component.mjs +4 -3
  251. package/wizard/esm2020/wizard.module.mjs +5 -4
  252. package/wizard/fesm2015/fundamental-ngx-core-wizard.mjs +7 -5
  253. package/wizard/fesm2015/fundamental-ngx-core-wizard.mjs.map +1 -1
  254. package/wizard/fesm2020/fundamental-ngx-core-wizard.mjs +7 -5
  255. package/wizard/fesm2020/fundamental-ngx-core-wizard.mjs.map +1 -1
  256. package/wizard/package.json +1 -1
  257. package/wizard/wizard.module.d.ts +2 -1
@@ -1 +1 @@
1
- {"version":3,"file":"fundamental-ngx-core-avatar-group.mjs","sources":["../../../../libs/core/src/lib/avatar-group/directives/avatar-group-item.directive.ts","../../../../libs/core/src/lib/avatar-group/avatar-group.component.ts","../../../../libs/core/src/lib/avatar-group/avatar-group.component.html","../../../../libs/core/src/lib/avatar-group/directives/avatar-group-focusable-avatar.directive.ts","../../../../libs/core/src/lib/avatar-group/directives/avatar-group-overflow-body.directive.ts","../../../../libs/core/src/lib/avatar-group/directives/avatar-group-overflow-item.directive.ts","../../../../libs/core/src/lib/avatar-group/directives/avatar-group-overflow-button.directive.ts","../../../../libs/core/src/lib/avatar-group/directives/avatar-group-overflow-button-text.directive.ts","../../../../libs/core/src/lib/avatar-group/directives/avatar-group-popover-control.directive.ts","../../../../libs/core/src/lib/avatar-group/avatar-group.module.ts","../../../../libs/core/src/lib/avatar-group/fundamental-ngx-core-avatar-group.ts"],"sourcesContent":["import { Directive, ElementRef, HostListener, Optional, Inject, forwardRef } from '@angular/core';\nimport { FocusableOption } from '@angular/cdk/a11y';\n\nimport { AvatarGroupComponent } from '../avatar-group.component';\nimport { AvatarGroupInterface } from '../avatar-group.interface';\n\n@Directive({\n // eslint-disable-next-line @angular-eslint/directive-selector\n selector: '[fd-avatar-group-item]',\n host: { class: 'fd-avatar-group__item' }\n})\nexport class AvatarGroupItemDirective implements FocusableOption {\n /** Item disable state */\n disabled = false;\n\n /** @hidden */\n constructor(\n private readonly _elementRef: ElementRef<HTMLElement>,\n @Optional() @Inject(forwardRef(() => AvatarGroupComponent)) private readonly _component: AvatarGroupInterface\n ) {}\n\n /** @hidden */\n get _element(): HTMLElement {\n return this._elementRef.nativeElement;\n }\n\n /** Handler for mouse events */\n @HostListener('click')\n onClick(): void {\n if (this._component) {\n this._component._setActiveItem(this);\n }\n }\n\n /** @hidden */\n focus(): void {\n this._element.focus();\n }\n}\n","import {\n AfterViewInit,\n ChangeDetectionStrategy,\n Component,\n ContentChildren,\n ElementRef,\n forwardRef,\n HostListener,\n Input,\n OnChanges,\n OnDestroy,\n OnInit,\n Optional,\n QueryList,\n ViewChild,\n ViewEncapsulation\n} from '@angular/core';\nimport { ViewportRuler } from '@angular/cdk/overlay';\nimport { FocusKeyManager } from '@angular/cdk/a11y';\nimport { DOWN_ARROW, UP_ARROW, LEFT_ARROW, RIGHT_ARROW, TAB } from '@angular/cdk/keycodes';\nimport { of, Subscription } from 'rxjs';\nimport { delay } from 'rxjs/operators';\n\nimport { Nullable } from '@fundamental-ngx/core/shared';\nimport { ColorAccent, KeyUtil, RtlService, Size } from '@fundamental-ngx/core/utils';\nimport { AvatarGroupItemDirective } from './directives/avatar-group-item.directive';\nimport { AvatarGroupInterface } from './avatar-group.interface';\n\nexport type AvatarGroupType = 'group' | 'individual';\nexport type AvatarGroupOverflowButtonColor = 'neutral' | 'random' | ColorAccent;\n\nlet avatarGroupCount = 0;\n\n@Component({\n selector: 'fd-avatar-group',\n templateUrl: './avatar-group.component.html',\n styleUrls: ['./avatar-group.component.scss'],\n encapsulation: ViewEncapsulation.None,\n changeDetection: ChangeDetectionStrategy.OnPush\n})\nexport class AvatarGroupComponent implements AvatarGroupInterface, OnChanges, OnInit, AfterViewInit, OnDestroy {\n /** Id of the Avatar Group. */\n @Input()\n id = `fd-avatar-group-${avatarGroupCount++}`;\n\n /** Apply user custom class. */\n @Input()\n class: string;\n\n /** The size of the Avatar Group. Options include: *xs*, *s*, *m*, *l* and *xl* (default: *s*). */\n @Input()\n size: Size = 's';\n\n /** The type of the Avatar Group. Options include: *group* and *individual* (default: *group*). */\n @Input()\n type: AvatarGroupType = 'group';\n\n /** Aria-label for Avatar Group. */\n @Input()\n ariaLabel: Nullable<string>;\n\n /** Counter for all avatars. */\n allItemsCount = 0;\n\n /** Counter for visible in overflow popover avatars. */\n overflowItemsCount = 0;\n\n /** @hidden Avatar Group items. */\n @ContentChildren(forwardRef(() => AvatarGroupItemDirective), { descendants: true })\n mainItems: QueryList<AvatarGroupItemDirective>;\n\n /** @hidden */\n @ViewChild('avatarGroupContainer')\n avatarGroupContainer: ElementRef<HTMLDivElement>;\n\n /** @hidden */\n rootClassNames: Record<string, boolean | undefined | null>;\n\n /** @hidden */\n get isGroupType(): boolean {\n return this.type === 'group';\n }\n\n /** @hidden */\n private get _avatarGroupWidth(): number {\n return this.avatarGroupContainer?.nativeElement?.offsetWidth;\n }\n\n /** @hidden */\n private get _avatarGroupItemWidth(): number {\n return this.mainItems.first?._element.offsetWidth ?? 0;\n }\n\n /** @hidden */\n private get _avatarGroupItemWithMarginsWidth(): number {\n if (!this.mainItems.first) {\n return this._avatarGroupItemWidth;\n }\n\n const elementStyles = getComputedStyle(this.mainItems.first._element);\n\n return (\n this._avatarGroupItemWidth +\n parseInt(elementStyles.marginLeft, 10) +\n parseInt(elementStyles.marginRight, 10)\n );\n }\n\n /** @hidden FocusKeyManager instance */\n private _keyboardEventsManager: FocusKeyManager<AvatarGroupItemDirective>;\n\n /** @hidden */\n private readonly _subscription = new Subscription();\n\n /** @hidden handles rtl service */\n private _dir: 'ltr' | 'rtl' | null = 'ltr';\n\n /** @hidden */\n constructor(private readonly _viewportRuler: ViewportRuler, @Optional() private _rtlService: RtlService) {}\n\n /** @hidden */\n ngOnInit(): void {\n this._subscription.add(this._viewportRuler.change().subscribe(() => this._onResize()));\n }\n\n /** @hidden */\n ngOnChanges(): void {\n this._assignCssClasses();\n }\n\n /** @hidden */\n ngAfterViewInit(): void {\n this._reset();\n\n this._subscription.add(\n of(true)\n .pipe(delay(5))\n .subscribe(() => this._collapseItems())\n );\n\n this._listenForItemChanges();\n this._setKeyboardEventsManager();\n this._subscribeToRtl();\n }\n\n /** @hidden */\n ngOnDestroy(): void {\n this._subscription.unsubscribe();\n }\n\n /** @hidden */\n @HostListener('keyup', ['$event'])\n keyUpHandler(event: KeyboardEvent): void {\n if (KeyUtil.isKeyCode(event, TAB)) {\n const index = this.mainItems.toArray().findIndex((item) => item._element === event.target);\n if (index !== -1) {\n this._keyboardEventsManager.setActiveItem(index);\n }\n }\n\n if (KeyUtil.isKeyCode(event, [DOWN_ARROW, UP_ARROW, LEFT_ARROW, RIGHT_ARROW])) {\n event.preventDefault();\n\n // passing the event to key manager so we get a change fired\n this._keyboardEventsManager.onKeydown(event);\n }\n }\n\n /** @hidden */\n _setActiveItem(item: AvatarGroupItemDirective): void {\n this._keyboardEventsManager.setActiveItem(item);\n }\n\n /** @hidden */\n private _onResize(): void {\n this._reset();\n this._collapseItems();\n }\n\n /** @hidden */\n private _reset(): void {\n this.allItemsCount = this.mainItems.length;\n this.overflowItemsCount = 0;\n\n this.mainItems.forEach((it) => {\n it._element.style.display = 'inline-block';\n it.disabled = false;\n });\n }\n\n /** @hidden */\n private _collapseItems(): void {\n const allItemsCounter = this.mainItems?.length || 0;\n let contentWidth = 0;\n let idx = 0;\n const avatarGroupItemWidth = this._avatarGroupItemWidth;\n const avatarGroupItemWithMarginsWidth = this._avatarGroupItemWithMarginsWidth;\n\n while (idx < allItemsCounter) {\n const newContentWidth =\n idx === 0 && this.isGroupType\n ? contentWidth + avatarGroupItemWidth\n : contentWidth + avatarGroupItemWithMarginsWidth;\n\n if (newContentWidth >= this._avatarGroupWidth) {\n // -1 because the last element in the loop will be replaced by the overflow button\n const newIdx = idx - 1;\n this.overflowItemsCount = allItemsCounter - newIdx;\n const mainItemsToHide = this.mainItems.toArray().slice(newIdx);\n mainItemsToHide.forEach((it) => {\n it._element.style.display = 'none';\n it.disabled = true;\n });\n\n break;\n }\n\n contentWidth = newContentWidth;\n idx++;\n }\n }\n\n /** @hidden */\n private _listenForItemChanges(): void {\n this._subscription.add(this.mainItems.changes.subscribe(() => this._onResize()));\n }\n\n /** @hidden */\n private _assignCssClasses(): void {\n this.rootClassNames = {\n 'fd-avatar-group': true,\n [`fd-avatar-group--${this.type}-type`]: !!this.type,\n [`fd-avatar-group--${this.size}`]: !!this.size,\n [this.class]: !!this.class\n };\n }\n\n /** @hidden */\n private _setKeyboardEventsManager(): void {\n this._keyboardEventsManager = new FocusKeyManager(this.mainItems)\n .withWrap()\n .withHorizontalOrientation(this._dir);\n }\n\n /** @hidden Rtl change subscription */\n private _subscribeToRtl(): void {\n if (!this._rtlService) {\n return;\n }\n\n const rtlSub = this._rtlService.rtl.subscribe((isRtl) => {\n this._dir = isRtl ? 'rtl' : 'ltr';\n\n this._keyboardEventsManager = this._keyboardEventsManager.withHorizontalOrientation(this._dir);\n });\n\n this._subscription.add(rtlSub);\n }\n}\n","<div #avatarGroupContainer [class]=\"rootClassNames\" [id]=\"id\" [attr.aria-label]=\"ariaLabel\">\n <ng-content></ng-content>\n</div>\n","import { Directive, ElementRef, Optional, HostBinding, HostListener, Input, Inject, forwardRef } from '@angular/core';\nimport { FocusableOption } from '@angular/cdk/a11y';\n\nimport { AvatarGroupOverflowBodyDirective } from './avatar-group-overflow-body.directive';\nimport { AvatarGroupInterface } from '../avatar-group.interface';\n\n@Directive({\n // eslint-disable-next-line @angular-eslint/directive-selector\n selector: '[fd-avatar-group-focusable-avatar]',\n host: { class: 'fd-avatar-group__focusable-avatar' }\n})\nexport class AvatarGroupFocusableAvatarDirective implements FocusableOption {\n /** Tabindex of the Avatar. */\n @Input()\n @HostBinding('attr.tabindex')\n tabindex = 0;\n\n /** @hidden */\n constructor(\n private readonly _elementRef: ElementRef<HTMLElement>,\n @Optional()\n @Inject(forwardRef(() => AvatarGroupOverflowBodyDirective))\n private readonly _component: AvatarGroupInterface\n ) {}\n\n /** @hidden */\n get _element(): HTMLElement {\n return this._elementRef.nativeElement;\n }\n\n /** Handler for mouse events */\n @HostListener('click')\n onClick(): void {\n if (this._component) {\n this._component._setActiveItem(this);\n }\n }\n\n /** @hidden */\n focus(): void {\n this._element.focus();\n }\n}\n","import {\n AfterViewInit,\n ContentChildren,\n Directive,\n forwardRef,\n HostListener,\n Input,\n OnDestroy,\n Optional,\n QueryList\n} from '@angular/core';\nimport { FocusKeyManager } from '@angular/cdk/a11y';\nimport { TAB, DOWN_ARROW, UP_ARROW, LEFT_ARROW, RIGHT_ARROW } from '@angular/cdk/keycodes';\nimport { Subscription } from 'rxjs';\n\nimport { KeyUtil, RtlService } from '@fundamental-ngx/core/utils';\nimport { AvatarGroupFocusableAvatarDirective } from './avatar-group-focusable-avatar.directive';\n\n@Directive({\n // eslint-disable-next-line @angular-eslint/directive-selector\n selector: '[fd-avatar-group-overflow-body]',\n host: {\n class: 'fd-avatar-group__overflow-body',\n '[class.fd-avatar-group__overflow-body--no-padding]': 'noPadding',\n '[class.fd-avatar-group__overflow-body--no-horizontal-scroll]': 'noHorizontalScroll',\n '[class.fd-avatar-group__overflow-body--no-vertical-scroll]': 'noVerticalScroll'\n }\n})\nexport class AvatarGroupOverflowBodyDirective implements AfterViewInit, OnDestroy {\n /** Remove the padding from the overflow body. */\n @Input()\n noPadding = false;\n\n /** Hide horizontal scrollbar from the overflow body. */\n @Input()\n noHorizontalScroll = true;\n\n /** Hide vertical scrollbar from the overflow body. */\n @Input()\n noVerticalScroll = true;\n\n /** @hidden Avatar Group Overflow items. */\n @ContentChildren(forwardRef(() => AvatarGroupFocusableAvatarDirective), { descendants: true })\n overflowItems: QueryList<AvatarGroupFocusableAvatarDirective>;\n\n /** @hidden FocusKeyManager instance */\n private _keyboardEventsManager: FocusKeyManager<AvatarGroupFocusableAvatarDirective>;\n\n /** @hidden */\n private readonly _subscription = new Subscription();\n\n /** @hidden handles rtl service */\n private _dir: 'ltr' | 'rtl' | null = 'ltr';\n\n /** @hidden */\n constructor(@Optional() private _rtlService: RtlService) {}\n\n /** @hidden */\n ngAfterViewInit(): void {\n this._listenForItemChanges();\n\n this._setKeyboardEventsManager();\n\n this._subscribeToRtl();\n }\n\n /** @hidden */\n ngOnDestroy(): void {\n this._subscription.unsubscribe();\n }\n\n /** @hidden */\n @HostListener('keyup', ['$event'])\n keyUpHandler(event: KeyboardEvent): void {\n if (KeyUtil.isKeyCode(event, TAB)) {\n const index = this.overflowItems.toArray().findIndex((item) => item._element === event.target);\n if (index !== -1) {\n this._keyboardEventsManager.setActiveItem(index);\n }\n }\n\n if (KeyUtil.isKeyCode(event, [DOWN_ARROW, UP_ARROW, LEFT_ARROW, RIGHT_ARROW])) {\n // passing the event to key manager so we get a change fired\n this._keyboardEventsManager.onKeydown(event);\n }\n }\n\n /** @hidden */\n _setActiveItem(item: AvatarGroupFocusableAvatarDirective): void {\n this._keyboardEventsManager.setActiveItem(item);\n }\n\n /** @hidden */\n private _listenForItemChanges(): void {\n this.overflowItems.changes.subscribe(() => this._setKeyboardEventsManager());\n }\n\n /** @hidden */\n private _setKeyboardEventsManager(): void {\n this._keyboardEventsManager = new FocusKeyManager(this.overflowItems)\n .withWrap()\n .withHorizontalOrientation(this._dir);\n\n this._keyboardEventsManager.setFirstItemActive();\n }\n\n /** @hidden Rtl change subscription */\n private _subscribeToRtl(): void {\n if (!this._rtlService) {\n return;\n }\n\n const rtlSub = this._rtlService.rtl.subscribe((isRtl) => {\n this._dir = isRtl ? 'rtl' : 'ltr';\n this._keyboardEventsManager.withHorizontalOrientation(this._dir);\n });\n\n this._subscription.add(rtlSub);\n }\n}\n","import { Directive } from '@angular/core';\n\nimport { AvatarGroupItemDirective } from './avatar-group-item.directive';\n\n@Directive({\n // eslint-disable-next-line @angular-eslint/directive-selector\n selector: '[fd-avatar-group-overflow-item]'\n})\nexport class AvatarGroupOverflowItemDirective extends AvatarGroupItemDirective {}\n","import { Directive, ElementRef, Input, OnChanges } from '@angular/core';\n\nimport { Size } from '@fundamental-ngx/core/utils';\nimport { applyCssClass } from '@fundamental-ngx/core/utils';\nimport { getRandomColorAccent } from '@fundamental-ngx/core/utils';\nimport { CssClassBuilder } from '@fundamental-ngx/core/utils';\n\nimport { AvatarGroupOverflowButtonColor } from '../avatar-group.component';\n\n@Directive({\n // eslint-disable-next-line @angular-eslint/directive-selector\n selector: '[fd-avatar-group-overflow-button]'\n})\nexport class AvatarGroupOverflowButtonDirective implements OnChanges, CssClassBuilder {\n /** User's custom classes. */\n @Input()\n class: string;\n\n /** The size of the overflow button.\n * Should be the same as the Avatar Group and Avatar size.\n * Options include: *xs*, *s*, *m*, *l* and *xl* (default: *s*). */\n @Input()\n size: Size = 's';\n\n /** A number from 1 to 10 representing the background color of the Avatar Group's overflow button.\n * Options include: *neutral*, *random*, *1*, *2*, *3*, *4*, *5*, *6*, *7*, *8*, *9*, *10* (default: *neutral*). */\n @Input()\n color: AvatarGroupOverflowButtonColor = 'neutral';\n\n /** @hidden */\n constructor(private readonly _elementRef: ElementRef) {}\n\n /** @hidden */\n ngOnChanges(): void {\n this.buildComponentCssClass();\n }\n\n /** @hidden */\n @applyCssClass\n buildComponentCssClass(): string[] {\n return [\n 'fd-button',\n 'fd-avatar-group__more-button',\n (this.color && this._getMoreButtonColorCssClass()) || '',\n this.size ? `fd-avatar-group__more-button--${this.size}` : '',\n this.class\n ];\n }\n\n /** @hidden */\n elementRef(): ElementRef<HTMLElement> {\n return this._elementRef;\n }\n\n /** @hidden */\n private _getMoreButtonColorCssClass(): string | null {\n if (this.color === 'random') {\n return `fd-avatar-group__more-button--accent-color-${getRandomColorAccent()}`;\n }\n\n if (!Number.isNaN(parseInt(this.color as string, 10))) {\n return `fd-avatar-group__more-button--accent-color-${this.color}`;\n }\n return null;\n }\n}\n","import { Directive } from '@angular/core';\n\n@Directive({\n // eslint-disable-next-line @angular-eslint/directive-selector\n selector: '[fd-avatar-group-overflow-button-text]',\n host: { class: 'fd-button__text fd-avatar-group__button-text' }\n})\nexport class AvatarGroupOverflowButtonTextDirective {}\n","import { Directive, HostBinding, Input } from '@angular/core';\n\n/** Needed to bind specific class to group type popover control. */\n@Directive({\n // eslint-disable-next-line @angular-eslint/directive-selector\n selector: '[fd-avatar-group-popover-control]',\n host: { class: 'fd-avatar-group__popover-control' }\n})\nexport class AvatarGroupPopoverControlDirective {\n /** Tabindex of the popover control. */\n @Input()\n @HostBinding('attr.tabindex')\n tabindex = 0;\n\n /** Role of the popover control. */\n @Input()\n @HostBinding('attr.role')\n role = 'button';\n}\n","import { NgModule } from '@angular/core';\nimport { CommonModule } from '@angular/common';\n\nimport { AvatarGroupComponent } from './avatar-group.component';\nimport { AvatarGroupItemDirective } from './directives/avatar-group-item.directive';\nimport { AvatarGroupOverflowBodyDirective } from './directives/avatar-group-overflow-body.directive';\nimport { AvatarGroupOverflowItemDirective } from './directives/avatar-group-overflow-item.directive';\nimport { AvatarGroupOverflowButtonDirective } from './directives/avatar-group-overflow-button.directive';\nimport { AvatarGroupOverflowButtonTextDirective } from './directives/avatar-group-overflow-button-text.directive';\nimport { AvatarGroupFocusableAvatarDirective } from './directives/avatar-group-focusable-avatar.directive';\nimport { AvatarGroupPopoverControlDirective } from './directives/avatar-group-popover-control.directive';\n\n@NgModule({\n imports: [CommonModule],\n exports: [\n AvatarGroupComponent,\n AvatarGroupItemDirective,\n AvatarGroupFocusableAvatarDirective,\n AvatarGroupPopoverControlDirective,\n AvatarGroupOverflowBodyDirective,\n AvatarGroupOverflowItemDirective,\n AvatarGroupOverflowButtonDirective,\n AvatarGroupOverflowButtonTextDirective\n ],\n declarations: [\n AvatarGroupComponent,\n AvatarGroupItemDirective,\n AvatarGroupFocusableAvatarDirective,\n AvatarGroupPopoverControlDirective,\n AvatarGroupOverflowBodyDirective,\n AvatarGroupOverflowItemDirective,\n AvatarGroupOverflowButtonDirective,\n AvatarGroupOverflowButtonTextDirective\n ]\n})\nexport class AvatarGroupModule {}\n","/**\n * Generated bundle index. Do not edit.\n */\n\nexport * from './public_api';\n"],"names":[],"mappings":";;;;;;;;;;;;MAWa,wBAAwB;;IAKjC,YACqB,WAAoC,EACwB,UAAgC;QAD5F,gBAAW,GAAX,WAAW,CAAyB;QACwB,eAAU,GAAV,UAAU,CAAsB;;QALjH,aAAQ,GAAG,KAAK,CAAC;KAMb;;IAGJ,IAAI,QAAQ;QACR,OAAO,IAAI,CAAC,WAAW,CAAC,aAAa,CAAC;KACzC;;IAID,OAAO;QACH,IAAI,IAAI,CAAC,UAAU,EAAE;YACjB,IAAI,CAAC,UAAU,CAAC,cAAc,CAAC,IAAI,CAAC,CAAC;SACxC;KACJ;;IAGD,KAAK;QACD,IAAI,CAAC,QAAQ,CAAC,KAAK,EAAE,CAAC;KACzB;;qHA1BQ,wBAAwB,4CAOT,UAAU,CAAC,MAAM,oBAAoB,CAAC;yGAPrD,wBAAwB;2FAAxB,wBAAwB;kBALpC,SAAS;mBAAC;;oBAEP,QAAQ,EAAE,wBAAwB;oBAClC,IAAI,EAAE,EAAE,KAAK,EAAE,uBAAuB,EAAE;iBAC3C;;;8BAQQ,QAAQ;;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C,kCAAkC;wBAClC,sCAAsC;qBACzC;iBACJ;;;AClCD;;;;;;"}
1
+ {"version":3,"file":"fundamental-ngx-core-avatar-group.mjs","sources":["../../../../libs/core/src/lib/avatar-group/directives/avatar-group-item.directive.ts","../../../../libs/core/src/lib/avatar-group/avatar-group.component.ts","../../../../libs/core/src/lib/avatar-group/avatar-group.component.html","../../../../libs/core/src/lib/avatar-group/directives/avatar-group-focusable-avatar.directive.ts","../../../../libs/core/src/lib/avatar-group/directives/avatar-group-overflow-body.directive.ts","../../../../libs/core/src/lib/avatar-group/directives/avatar-group-overflow-item.directive.ts","../../../../libs/core/src/lib/avatar-group/directives/avatar-group-overflow-button.directive.ts","../../../../libs/core/src/lib/avatar-group/directives/avatar-group-overflow-button-text.directive.ts","../../../../libs/core/src/lib/avatar-group/directives/avatar-group-popover-control.directive.ts","../../../../libs/core/src/lib/avatar-group/avatar-group.module.ts","../../../../libs/core/src/lib/avatar-group/fundamental-ngx-core-avatar-group.ts"],"sourcesContent":["import { Directive, ElementRef, HostListener, Optional, Inject, forwardRef } from '@angular/core';\nimport { FocusableOption } from '@angular/cdk/a11y';\n\nimport { AvatarGroupComponent } from '../avatar-group.component';\nimport { AvatarGroupInterface } from '../avatar-group.interface';\n\n@Directive({\n // eslint-disable-next-line @angular-eslint/directive-selector\n selector: '[fd-avatar-group-item]',\n host: { class: 'fd-avatar-group__item' }\n})\nexport class AvatarGroupItemDirective implements FocusableOption {\n /** Item disable state */\n disabled = false;\n\n /** @hidden */\n constructor(\n private readonly _elementRef: ElementRef<HTMLElement>,\n @Optional() @Inject(forwardRef(() => AvatarGroupComponent)) private readonly _component: AvatarGroupInterface\n ) {}\n\n /** @hidden */\n get _element(): HTMLElement {\n return this._elementRef.nativeElement;\n }\n\n /** Handler for mouse events */\n @HostListener('click')\n onClick(): void {\n if (this._component) {\n this._component._setActiveItem(this);\n }\n }\n\n /** @hidden */\n focus(): void {\n this._element.focus();\n }\n}\n","import {\n AfterViewInit,\n ChangeDetectionStrategy,\n Component,\n ContentChildren,\n ElementRef,\n forwardRef,\n HostListener,\n Input,\n OnChanges,\n OnDestroy,\n OnInit,\n Optional,\n QueryList,\n ViewChild,\n ViewEncapsulation\n} from '@angular/core';\nimport { ViewportRuler } from '@angular/cdk/overlay';\nimport { FocusKeyManager } from '@angular/cdk/a11y';\nimport { DOWN_ARROW, UP_ARROW, LEFT_ARROW, RIGHT_ARROW, TAB } from '@angular/cdk/keycodes';\nimport { of, Subscription } from 'rxjs';\nimport { delay } from 'rxjs/operators';\n\nimport { Nullable } from '@fundamental-ngx/core/shared';\nimport { ColorAccent, KeyUtil, RtlService, Size } from '@fundamental-ngx/core/utils';\nimport { AvatarGroupItemDirective } from './directives/avatar-group-item.directive';\nimport { AvatarGroupInterface } from './avatar-group.interface';\n\nexport type AvatarGroupType = 'group' | 'individual';\nexport type AvatarGroupOverflowButtonColor = 'neutral' | 'random' | ColorAccent;\n\nlet avatarGroupCount = 0;\n\n@Component({\n selector: 'fd-avatar-group',\n templateUrl: './avatar-group.component.html',\n styleUrls: ['./avatar-group.component.scss'],\n encapsulation: ViewEncapsulation.None,\n changeDetection: ChangeDetectionStrategy.OnPush\n})\nexport class AvatarGroupComponent implements AvatarGroupInterface, OnChanges, OnInit, AfterViewInit, OnDestroy {\n /** Id of the Avatar Group. */\n @Input()\n id = `fd-avatar-group-${avatarGroupCount++}`;\n\n /** Apply user custom class. */\n @Input()\n class: string;\n\n /** The size of the Avatar Group. Options include: *xs*, *s*, *m*, *l* and *xl* (default: *s*). */\n @Input()\n size: Size = 's';\n\n /** The type of the Avatar Group. Options include: *group* and *individual* (default: *group*). */\n @Input()\n type: AvatarGroupType = 'group';\n\n /** Aria-label for Avatar Group. */\n @Input()\n ariaLabel: Nullable<string>;\n\n /** Counter for all avatars. */\n allItemsCount = 0;\n\n /** Counter for visible in overflow popover avatars. */\n overflowItemsCount = 0;\n\n /** @hidden Avatar Group items. */\n @ContentChildren(forwardRef(() => AvatarGroupItemDirective), { descendants: true })\n mainItems: QueryList<AvatarGroupItemDirective>;\n\n /** @hidden */\n @ViewChild('avatarGroupContainer')\n avatarGroupContainer: ElementRef<HTMLDivElement>;\n\n /** @hidden */\n rootClassNames: Record<string, boolean | undefined | null>;\n\n /** @hidden */\n get isGroupType(): boolean {\n return this.type === 'group';\n }\n\n /** @hidden */\n private get _avatarGroupWidth(): number {\n return this.avatarGroupContainer?.nativeElement?.offsetWidth;\n }\n\n /** @hidden */\n private get _avatarGroupItemWidth(): number {\n return this.mainItems.first?._element.offsetWidth ?? 0;\n }\n\n /** @hidden */\n private get _avatarGroupItemWithMarginsWidth(): number {\n if (!this.mainItems.first) {\n return this._avatarGroupItemWidth;\n }\n\n const elementStyles = getComputedStyle(this.mainItems.first._element);\n\n return (\n this._avatarGroupItemWidth +\n parseInt(elementStyles.marginLeft, 10) +\n parseInt(elementStyles.marginRight, 10)\n );\n }\n\n /** @hidden FocusKeyManager instance */\n private _keyboardEventsManager: FocusKeyManager<AvatarGroupItemDirective>;\n\n /** @hidden */\n private readonly _subscription = new Subscription();\n\n /** @hidden handles rtl service */\n private _dir: 'ltr' | 'rtl' | null = 'ltr';\n\n /** @hidden */\n constructor(private readonly _viewportRuler: ViewportRuler, @Optional() private _rtlService: RtlService) {}\n\n /** @hidden */\n ngOnInit(): void {\n this._subscription.add(this._viewportRuler.change().subscribe(() => this._onResize()));\n }\n\n /** @hidden */\n ngOnChanges(): void {\n this._assignCssClasses();\n }\n\n /** @hidden */\n ngAfterViewInit(): void {\n this._reset();\n\n this._subscription.add(\n of(true)\n .pipe(delay(5))\n .subscribe(() => this._collapseItems())\n );\n\n this._listenForItemChanges();\n this._setKeyboardEventsManager();\n this._subscribeToRtl();\n }\n\n /** @hidden */\n ngOnDestroy(): void {\n this._subscription.unsubscribe();\n }\n\n /** @hidden */\n @HostListener('keyup', ['$event'])\n keyUpHandler(event: KeyboardEvent): void {\n if (KeyUtil.isKeyCode(event, TAB)) {\n const index = this.mainItems.toArray().findIndex((item) => item._element === event.target);\n if (index !== -1) {\n this._keyboardEventsManager.setActiveItem(index);\n }\n }\n\n if (KeyUtil.isKeyCode(event, [DOWN_ARROW, UP_ARROW, LEFT_ARROW, RIGHT_ARROW])) {\n event.preventDefault();\n\n // passing the event to key manager so we get a change fired\n this._keyboardEventsManager.onKeydown(event);\n }\n }\n\n /** @hidden */\n _setActiveItem(item: AvatarGroupItemDirective): void {\n this._keyboardEventsManager.setActiveItem(item);\n }\n\n /** @hidden */\n private _onResize(): void {\n this._reset();\n this._collapseItems();\n }\n\n /** @hidden */\n private _reset(): void {\n this.allItemsCount = this.mainItems.length;\n this.overflowItemsCount = 0;\n\n this.mainItems.forEach((it) => {\n it._element.style.display = 'inline-block';\n it.disabled = false;\n });\n }\n\n /** @hidden */\n private _collapseItems(): void {\n const allItemsCounter = this.mainItems?.length || 0;\n let contentWidth = 0;\n let idx = 0;\n const avatarGroupItemWidth = this._avatarGroupItemWidth;\n const avatarGroupItemWithMarginsWidth = this._avatarGroupItemWithMarginsWidth;\n\n while (idx < allItemsCounter) {\n const newContentWidth =\n idx === 0 && this.isGroupType\n ? contentWidth + avatarGroupItemWidth\n : contentWidth + avatarGroupItemWithMarginsWidth;\n\n if (newContentWidth >= this._avatarGroupWidth) {\n // -1 because the last element in the loop will be replaced by the overflow button\n const newIdx = idx - 1;\n this.overflowItemsCount = allItemsCounter - newIdx;\n const mainItemsToHide = this.mainItems.toArray().slice(newIdx);\n mainItemsToHide.forEach((it) => {\n it._element.style.display = 'none';\n it.disabled = true;\n });\n\n break;\n }\n\n contentWidth = newContentWidth;\n idx++;\n }\n }\n\n /** @hidden */\n private _listenForItemChanges(): void {\n this._subscription.add(this.mainItems.changes.subscribe(() => this._onResize()));\n }\n\n /** @hidden */\n private _assignCssClasses(): void {\n this.rootClassNames = {\n 'fd-avatar-group': true,\n [`fd-avatar-group--${this.type}-type`]: !!this.type,\n [`fd-avatar-group--${this.size}`]: !!this.size,\n [this.class]: !!this.class\n };\n }\n\n /** @hidden */\n private _setKeyboardEventsManager(): void {\n this._keyboardEventsManager = new FocusKeyManager(this.mainItems)\n .withWrap()\n .withHorizontalOrientation(this._dir);\n }\n\n /** @hidden Rtl change subscription */\n private _subscribeToRtl(): void {\n if (!this._rtlService) {\n return;\n }\n\n const rtlSub = this._rtlService.rtl.subscribe((isRtl) => {\n this._dir = isRtl ? 'rtl' : 'ltr';\n\n this._keyboardEventsManager = this._keyboardEventsManager.withHorizontalOrientation(this._dir);\n });\n\n this._subscription.add(rtlSub);\n }\n}\n","<div #avatarGroupContainer [class]=\"rootClassNames\" [id]=\"id\" [attr.aria-label]=\"ariaLabel\">\n <ng-content></ng-content>\n</div>\n","import { Directive, ElementRef, Optional, HostBinding, HostListener, Input, Inject, forwardRef } from '@angular/core';\nimport { FocusableOption } from '@angular/cdk/a11y';\n\nimport { AvatarGroupOverflowBodyDirective } from './avatar-group-overflow-body.directive';\nimport { AvatarGroupInterface } from '../avatar-group.interface';\n\n@Directive({\n // eslint-disable-next-line @angular-eslint/directive-selector\n selector: '[fd-avatar-group-focusable-avatar]',\n host: { class: 'fd-avatar-group__focusable-avatar' }\n})\nexport class AvatarGroupFocusableAvatarDirective implements FocusableOption {\n /** Tabindex of the Avatar. */\n @Input()\n @HostBinding('attr.tabindex')\n tabindex = 0;\n\n /** @hidden */\n constructor(\n private readonly _elementRef: ElementRef<HTMLElement>,\n @Optional()\n @Inject(forwardRef(() => AvatarGroupOverflowBodyDirective))\n private readonly _component: AvatarGroupInterface\n ) {}\n\n /** @hidden */\n get _element(): HTMLElement {\n return this._elementRef.nativeElement;\n }\n\n /** Handler for mouse events */\n @HostListener('click')\n onClick(): void {\n if (this._component) {\n this._component._setActiveItem(this);\n }\n }\n\n /** @hidden */\n focus(): void {\n this._element.focus();\n }\n}\n","import {\n AfterViewInit,\n ContentChildren,\n Directive,\n forwardRef,\n HostListener,\n Input,\n OnDestroy,\n Optional,\n QueryList\n} from '@angular/core';\nimport { FocusKeyManager } from '@angular/cdk/a11y';\nimport { TAB, DOWN_ARROW, UP_ARROW, LEFT_ARROW, RIGHT_ARROW } from '@angular/cdk/keycodes';\nimport { Subscription } from 'rxjs';\n\nimport { KeyUtil, RtlService } from '@fundamental-ngx/core/utils';\nimport { AvatarGroupFocusableAvatarDirective } from './avatar-group-focusable-avatar.directive';\n\n@Directive({\n // eslint-disable-next-line @angular-eslint/directive-selector\n selector: '[fd-avatar-group-overflow-body]',\n host: {\n class: 'fd-avatar-group__overflow-body',\n '[class.fd-avatar-group__overflow-body--no-padding]': 'noPadding',\n '[class.fd-avatar-group__overflow-body--no-horizontal-scroll]': 'noHorizontalScroll',\n '[class.fd-avatar-group__overflow-body--no-vertical-scroll]': 'noVerticalScroll'\n }\n})\nexport class AvatarGroupOverflowBodyDirective implements AfterViewInit, OnDestroy {\n /** Remove the padding from the overflow body. */\n @Input()\n noPadding = false;\n\n /** Hide horizontal scrollbar from the overflow body. */\n @Input()\n noHorizontalScroll = true;\n\n /** Hide vertical scrollbar from the overflow body. */\n @Input()\n noVerticalScroll = true;\n\n /** @hidden Avatar Group Overflow items. */\n @ContentChildren(forwardRef(() => AvatarGroupFocusableAvatarDirective), { descendants: true })\n overflowItems: QueryList<AvatarGroupFocusableAvatarDirective>;\n\n /** @hidden FocusKeyManager instance */\n private _keyboardEventsManager: FocusKeyManager<AvatarGroupFocusableAvatarDirective>;\n\n /** @hidden */\n private readonly _subscription = new Subscription();\n\n /** @hidden handles rtl service */\n private _dir: 'ltr' | 'rtl' | null = 'ltr';\n\n /** @hidden */\n constructor(@Optional() private _rtlService: RtlService) {}\n\n /** @hidden */\n ngAfterViewInit(): void {\n this._listenForItemChanges();\n\n this._setKeyboardEventsManager();\n\n this._subscribeToRtl();\n }\n\n /** @hidden */\n ngOnDestroy(): void {\n this._subscription.unsubscribe();\n }\n\n /** @hidden */\n @HostListener('keyup', ['$event'])\n keyUpHandler(event: KeyboardEvent): void {\n if (KeyUtil.isKeyCode(event, TAB)) {\n const index = this.overflowItems.toArray().findIndex((item) => item._element === event.target);\n if (index !== -1) {\n this._keyboardEventsManager.setActiveItem(index);\n }\n }\n\n if (KeyUtil.isKeyCode(event, [DOWN_ARROW, UP_ARROW, LEFT_ARROW, RIGHT_ARROW])) {\n // passing the event to key manager so we get a change fired\n this._keyboardEventsManager.onKeydown(event);\n }\n }\n\n /** @hidden */\n _setActiveItem(item: AvatarGroupFocusableAvatarDirective): void {\n this._keyboardEventsManager.setActiveItem(item);\n }\n\n /** @hidden */\n private _listenForItemChanges(): void {\n this.overflowItems.changes.subscribe(() => this._setKeyboardEventsManager());\n }\n\n /** @hidden */\n private _setKeyboardEventsManager(): void {\n this._keyboardEventsManager = new FocusKeyManager(this.overflowItems)\n .withWrap()\n .withHorizontalOrientation(this._dir);\n\n this._keyboardEventsManager.setFirstItemActive();\n }\n\n /** @hidden Rtl change subscription */\n private _subscribeToRtl(): void {\n if (!this._rtlService) {\n return;\n }\n\n const rtlSub = this._rtlService.rtl.subscribe((isRtl) => {\n this._dir = isRtl ? 'rtl' : 'ltr';\n this._keyboardEventsManager.withHorizontalOrientation(this._dir);\n });\n\n this._subscription.add(rtlSub);\n }\n}\n","import { Directive } from '@angular/core';\n\nimport { AvatarGroupItemDirective } from './avatar-group-item.directive';\n\n@Directive({\n // eslint-disable-next-line @angular-eslint/directive-selector\n selector: '[fd-avatar-group-overflow-item]'\n})\nexport class AvatarGroupOverflowItemDirective extends AvatarGroupItemDirective {}\n","import { Directive, ElementRef, Input, OnChanges, OnInit } from '@angular/core';\n\nimport { Size } from '@fundamental-ngx/core/utils';\nimport { applyCssClass } from '@fundamental-ngx/core/utils';\nimport { getRandomColorAccent } from '@fundamental-ngx/core/utils';\nimport { CssClassBuilder } from '@fundamental-ngx/core/utils';\n\nimport { AvatarGroupOverflowButtonColor } from '../avatar-group.component';\n\n@Directive({\n // eslint-disable-next-line @angular-eslint/directive-selector\n selector: '[fd-avatar-group-overflow-button]'\n})\nexport class AvatarGroupOverflowButtonDirective implements OnInit, OnChanges, CssClassBuilder {\n /** User's custom classes. */\n @Input()\n class: string;\n\n /** The size of the overflow button.\n * Should be the same as the Avatar Group and Avatar size.\n * Options include: *xs*, *s*, *m*, *l* and *xl* (default: *s*). */\n @Input()\n size: Size = 's';\n\n /** A number from 1 to 10 representing the background color of the Avatar Group's overflow button.\n * Options include: *neutral*, *random*, *1*, *2*, *3*, *4*, *5*, *6*, *7*, *8*, *9*, *10* (default: *neutral*). */\n @Input()\n color: AvatarGroupOverflowButtonColor = 'neutral';\n\n /** @hidden */\n constructor(private readonly _elementRef: ElementRef) {}\n\n /** @hidden */\n ngOnInit(): void {\n this.buildComponentCssClass();\n }\n\n /** @hidden */\n ngOnChanges(): void {\n this.buildComponentCssClass();\n }\n\n /** @hidden */\n @applyCssClass\n buildComponentCssClass(): string[] {\n return [\n 'fd-button',\n 'fd-avatar-group__more-button',\n (this.color && this._getMoreButtonColorCssClass()) || '',\n this.size ? `fd-avatar-group__more-button--${this.size}` : '',\n this.class\n ];\n }\n\n /** @hidden */\n elementRef(): ElementRef<HTMLElement> {\n return this._elementRef;\n }\n\n /** @hidden */\n private _getMoreButtonColorCssClass(): string | null {\n if (this.color === 'random') {\n return `fd-avatar-group__more-button--accent-color-${getRandomColorAccent()}`;\n }\n\n if (!Number.isNaN(parseInt(this.color as string, 10))) {\n return `fd-avatar-group__more-button--accent-color-${this.color}`;\n }\n return null;\n }\n}\n","import { Directive } from '@angular/core';\n\n@Directive({\n // eslint-disable-next-line @angular-eslint/directive-selector\n selector: '[fd-avatar-group-overflow-button-text]',\n host: { class: 'fd-button__text fd-avatar-group__button-text' }\n})\nexport class AvatarGroupOverflowButtonTextDirective {}\n","import { Directive, HostBinding, Input } from '@angular/core';\n\n/** Needed to bind specific class to group type popover control. */\n@Directive({\n // eslint-disable-next-line @angular-eslint/directive-selector\n selector: '[fd-avatar-group-popover-control]',\n host: { class: 'fd-avatar-group__popover-control' }\n})\nexport class AvatarGroupPopoverControlDirective {\n /** Tabindex of the popover control. */\n @Input()\n @HostBinding('attr.tabindex')\n tabindex = 0;\n\n /** Role of the popover control. */\n @Input()\n @HostBinding('attr.role')\n role = 'button';\n}\n","import { NgModule } from '@angular/core';\nimport { CommonModule } from '@angular/common';\n\nimport { AvatarGroupComponent } from './avatar-group.component';\nimport { AvatarGroupItemDirective } from './directives/avatar-group-item.directive';\nimport { AvatarGroupOverflowBodyDirective } from './directives/avatar-group-overflow-body.directive';\nimport { AvatarGroupOverflowItemDirective } from './directives/avatar-group-overflow-item.directive';\nimport { AvatarGroupOverflowButtonDirective } from './directives/avatar-group-overflow-button.directive';\nimport { AvatarGroupOverflowButtonTextDirective } from './directives/avatar-group-overflow-button-text.directive';\nimport { AvatarGroupFocusableAvatarDirective } from './directives/avatar-group-focusable-avatar.directive';\nimport { AvatarGroupPopoverControlDirective } from './directives/avatar-group-popover-control.directive';\n\n@NgModule({\n imports: [CommonModule],\n exports: [\n AvatarGroupComponent,\n AvatarGroupItemDirective,\n AvatarGroupFocusableAvatarDirective,\n AvatarGroupPopoverControlDirective,\n AvatarGroupOverflowBodyDirective,\n AvatarGroupOverflowItemDirective,\n AvatarGroupOverflowButtonDirective,\n AvatarGroupOverflowButtonTextDirective\n ],\n declarations: [\n AvatarGroupComponent,\n AvatarGroupItemDirective,\n AvatarGroupFocusableAvatarDirective,\n AvatarGroupPopoverControlDirective,\n AvatarGroupOverflowBodyDirective,\n AvatarGroupOverflowItemDirective,\n AvatarGroupOverflowButtonDirective,\n AvatarGroupOverflowButtonTextDirective\n ]\n})\nexport class AvatarGroupModule {}\n","/**\n * Generated bundle index. Do not edit.\n */\n\nexport * from './public_api';\n"],"names":[],"mappings":";;;;;;;;;;;;MAWa,wBAAwB;;IAKjC,YACqB,WAAoC,EACwB,UAAgC;QAD5F,gBAAW,GAAX,WAAW,CAAyB;QACwB,eAAU,GAAV,UAAU,CAAsB;;QALjH,aAAQ,GAAG,KAAK,CAAC;KAMb;;IAGJ,IAAI,QAAQ;QACR,OAAO,IAAI,CAAC,WAAW,CAAC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oB;QACpB,wBAAwB;QACxB,mCAAmC;QACnC,kCAAkC;QAClC,gCAAgC;QAChC,gCAAgC;QAChC,kCAAkC;QAClC,sCAAsC;+GAajC,iBAAiB,YAtBjB,CAAC,YAAY,CAAC;2FAsBd,iBAAiB;kBAvB7B,QAAQ;mBAAC;oBACN,OAAO,EAAE,CAAC,YAAY,CAAC;oBACvB,OAAO,EAAE;wBACL,oBAAoB;wBACpB,wBAAwB;wBACxB,mCAAmC;wBACnC,kCAAkC;wBAClC,gCAAgC;wBAChC,gCAAgC;wBAChC,kCAAkC;wBAClC,sCAAsC;qBACzC;oBACD,YAAY,EAAE;wBACV,oBAAoB;wBACpB,wBAAwB;wBACxB,mCAAmC;wBACnC,kCAAkC;wBAClC,gCAAgC;wBAChC,gCAAgC;wBAChC,kCAAkC;wBAClC,sCAAsC;qBACzC;iBACJ;;;AClCD;;;;;;"}
@@ -64,7 +64,7 @@ class BarComponent {
64
64
  }
65
65
  }
66
66
  BarComponent.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "13.2.4", ngImport: i0, type: BarComponent, deps: [{ token: i0.ElementRef }, { token: i1.ContentDensityService, optional: true }], target: i0.ɵɵFactoryTarget.Component });
67
- BarComponent.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "12.0.0", version: "13.2.4", type: BarComponent, selector: "[fd-bar]", inputs: { class: "class", barDesign: "barDesign", inPage: "inPage", inHomePage: "inHomePage", size: "size", cozy: "cozy" }, usesOnChanges: true, ngImport: i0, template: "<ng-content select=\"[fd-bar-left]\"></ng-content>\n<ng-content select=\"[fd-bar-middle]\"></ng-content>\n<ng-content select=\"[fd-bar-right]\"></ng-content>\n<ng-content></ng-content>\n", styles: ["/*!\n * Fundamental Library Styles v0.24.1-rc.1\n * Copyright (c) 2022 SAP SE or an SAP affiliate company.\n * Licensed under Apache License 2.0 (https://github.com/SAP/fundamental-styles/blob/main/LICENSE)\n */.fd-bar{font-size:var(--sapFontSize);line-height:var(--sapContent_LineHeight);color:var(--sapTextColor);font-family:var(--sapFontFamily);font-weight:400;box-sizing:border-box;padding:0;margin:0;border:0;height:2.5rem;background:var(--sapPageHeader_Background);box-shadow:var(--sapContent_HeaderShadow);display:flex;flex-direction:row;justify-content:space-between;padding:0 1rem}.fd-bar:before,.fd-bar:after{box-sizing:inherit;font-size:inherit}.fd-bar__left,.fd-bar__middle,.fd-bar__right{font-size:var(--sapFontSize);line-height:var(--sapContent_LineHeight);color:var(--sapTextColor);font-family:var(--sapFontFamily);font-weight:400;box-sizing:border-box;padding:0;margin:0;border:0;display:flex;align-items:center;flex:1 1 auto;width:100%;max-width:100%}.fd-bar__left:before,.fd-bar__left:after,.fd-bar__middle:before,.fd-bar__middle:after,.fd-bar__right:before,.fd-bar__right:after{box-sizing:inherit;font-size:inherit}.fd-bar__middle{padding:0 var(--fdBar_Middle_Area_Padding_X);justify-content:center}.fd-bar__middle:only-child{padding:0}.fd-bar__left{padding-left:0;padding-right:var(--fdBar_Left_Area_Padding_Right)}[dir=rtl] .fd-bar__left,.fd-bar__left[dir=rtl]{padding-right:0;padding-left:var(--fdBar_Left_Area_Padding_Right)}.fd-bar__right{padding-left:--fdBar_Right_Area_Padding_Left;padding-right:0;justify-content:flex-end}[dir=rtl] .fd-bar__right,.fd-bar__right[dir=rtl]{padding-right:--fdBar_Right_Area_Padding_Left;padding-left:0}.fd-bar__element{font-size:var(--sapFontSize);line-height:var(--sapContent_LineHeight);color:var(--sapTextColor);font-family:var(--sapFontFamily);font-weight:400;box-sizing:border-box;padding:0;margin:0;border:0;display:flex;align-items:center;justify-content:center;margin-right:.5rem;max-width:100%;max-height:100%}.fd-bar__element:before,.fd-bar__element:after{box-sizing:inherit;font-size:inherit}[dir=rtl] .fd-bar__element,.fd-bar__element[dir=rtl]{margin-right:0;margin-left:.5rem}.fd-bar__element--full-width{width:100%}.fd-bar__element--full-width>*:first-child{flex-grow:1}.fd-bar__element:last-child{margin-right:0}[dir=rtl] .fd-bar__element:last-child,.fd-bar__element:last-child[dir=rtl]{margin-left:0;margin-right:0}.fd-bar--header{height:2.5rem;background:var(--sapPageHeader_Background);box-shadow:var(--sapContent_HeaderShadow);z-index:1}.fd-bar--subheader{height:2.25rem;background:var(--sapPageHeader_Background);box-shadow:var(--sapContent_HeaderShadow);padding-bottom:.25rem;z-index:1}.fd-bar--header-with-subheader{height:2.5rem;background:var(--sapPageHeader_Background);box-shadow:none;position:relative;z-index:2}.fd-bar--footer{height:2.5rem;background:var(--sapPageFooter_Background);box-shadow:none;border-top:.0625rem solid var(--sapPageFooter_BorderColor)}.fd-bar--floating-footer{height:2.5rem;background:var(--sapPageFooter_Background);box-shadow:var(--sapContent_Shadow1);border-radius:var(--sapElement_BorderCornerRadius);border:none;opacity:1;z-index:1000;position:absolute;bottom:0;left:0;right:0}.fd-bar--cozy,.fd-bar--cozy.fd-bar--header,.fd-bar--cozy.fd-bar--footer,.fd-bar--cozy.fd-bar--floating-footer{height:2.75rem}.fd-bar--cozy.fd-bar--subheader{height:3rem;padding-bottom:.25rem}.fd-bar--page,.fd-bar--home-page{padding:0 1rem}.fd-bar--page.fd-bar--floating-footer,.fd-bar--home-page.fd-bar--floating-footer{padding:0 .5rem;margin-top:.5rem;margin-bottom:.5rem;left:.5rem;right:.5rem}.fd-bar--page-s{padding:0 1rem}.fd-bar--page-s.fd-bar--floating-footer{padding:0 .5rem;margin-top:.5rem;margin-bottom:.5rem;left:1rem;right:1rem}.fd-bar--home-page-s{padding:0 .5rem}.fd-bar--home-page-s.fd-bar--floating-footer{padding:0 .5rem;margin-top:.5rem;margin-bottom:.5rem;left:1rem;right:1rem}.fd-bar--page-m_l,.fd-bar--home-page-m_l{padding:0 2rem}.fd-bar--page-m_l.fd-bar--floating-footer,.fd-bar--home-page-m_l.fd-bar--floating-footer{padding:0 .5rem;margin-top:.5rem;margin-bottom:.5rem;left:2rem;right:2rem}.fd-bar--page-xl,.fd-bar--home-page-xl{padding:0 3rem}.fd-bar--page-xl.fd-bar--floating-footer,.fd-bar--home-page-xl.fd-bar--floating-footer{padding:0 .5rem;margin-top:.5rem;margin-bottom:.5rem;left:3rem;right:3rem}.fd-bar--responsive-paddings{margin-top:.5rem;margin-bottom:.5rem}@media (max-width: 599px){.fd-bar--responsive-paddings{left:1rem;right:1rem}}@media (min-width: 600px) and (max-width: 1439px){.fd-bar--responsive-paddings{left:2rem;right:2rem}}@media (min-width: 1440px){.fd-bar--responsive-paddings{left:3rem;right:3rem}}\n"], changeDetection: i0.ChangeDetectionStrategy.OnPush, encapsulation: i0.ViewEncapsulation.None });
67
+ BarComponent.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "12.0.0", version: "13.2.4", type: BarComponent, selector: "[fd-bar]", inputs: { class: "class", barDesign: "barDesign", inPage: "inPage", inHomePage: "inHomePage", size: "size", cozy: "cozy" }, usesOnChanges: true, ngImport: i0, template: "<ng-content select=\"[fd-bar-left]\"></ng-content>\n<ng-content select=\"[fd-bar-middle]\"></ng-content>\n<ng-content select=\"[fd-bar-right]\"></ng-content>\n<ng-content></ng-content>\n", styles: ["/*!\n * Fundamental Library Styles v0.24.1-rc.1\n * Copyright (c) 2022 SAP SE or an SAP affiliate company.\n * Licensed under Apache License 2.0 (https://github.com/SAP/fundamental-styles/blob/main/LICENSE)\n */.fd-bar{font-size:var(--sapFontSize);line-height:var(--sapContent_LineHeight);color:var(--sapTextColor);font-family:var(--sapFontFamily);font-weight:400;box-sizing:border-box;padding:0;margin:0;border:0;height:2.5rem;background:var(--sapPageHeader_Background);box-shadow:var(--sapContent_HeaderShadow);display:flex;flex-direction:row;justify-content:space-between;padding:0 1rem}.fd-bar:before,.fd-bar:after{box-sizing:inherit;font-size:inherit}.fd-bar__left,.fd-bar__middle,.fd-bar__right{font-size:var(--sapFontSize);line-height:var(--sapContent_LineHeight);color:var(--sapTextColor);font-family:var(--sapFontFamily);font-weight:400;box-sizing:border-box;padding:0;margin:0;border:0;display:flex;align-items:center;flex:1 1 auto;width:100%;max-width:100%}.fd-bar__left:before,.fd-bar__left:after,.fd-bar__middle:before,.fd-bar__middle:after,.fd-bar__right:before,.fd-bar__right:after{box-sizing:inherit;font-size:inherit}.fd-bar__middle{padding:0 var(--fdBar_Middle_Area_Padding_X);justify-content:center}.fd-bar__middle:only-child{padding:0}.fd-bar__left{padding-left:0;padding-right:var(--fdBar_Left_Area_Padding_Right)}[dir=rtl] .fd-bar__left,.fd-bar__left[dir=rtl]{padding-right:0;padding-left:var(--fdBar_Left_Area_Padding_Right)}.fd-bar__right{padding-left:--fdBar_Right_Area_Padding_Left;padding-right:0;justify-content:flex-end}[dir=rtl] .fd-bar__right,.fd-bar__right[dir=rtl]{padding-right:--fdBar_Right_Area_Padding_Left;padding-left:0}.fd-bar__element{font-size:var(--sapFontSize);line-height:var(--sapContent_LineHeight);color:var(--sapTextColor);font-family:var(--sapFontFamily);font-weight:400;box-sizing:border-box;padding:0;margin:0;border:0;display:flex;align-items:center;justify-content:center;margin-right:.5rem;max-width:100%;max-height:100%}.fd-bar__element:before,.fd-bar__element:after{box-sizing:inherit;font-size:inherit}[dir=rtl] .fd-bar__element,.fd-bar__element[dir=rtl]{margin-right:0;margin-left:.5rem}.fd-bar__element--full-width{width:100%}.fd-bar__element--full-width>*:first-child{flex-grow:1}.fd-bar__element:last-child{margin-right:0}[dir=rtl] .fd-bar__element:last-child,.fd-bar__element:last-child[dir=rtl]{margin-left:0;margin-right:0}.fd-bar--header{height:2.5rem;background:var(--sapPageHeader_Background);box-shadow:var(--sapContent_HeaderShadow);z-index:1}.fd-bar--subheader{height:2.25rem;background:var(--sapPageHeader_Background);box-shadow:var(--sapContent_HeaderShadow);padding-bottom:.25rem;z-index:1}.fd-bar--header-with-subheader{height:2.5rem;background:var(--sapPageHeader_Background);box-shadow:none;position:relative;z-index:2}.fd-bar--footer{height:2.5rem;background:var(--sapPageFooter_Background);box-shadow:none;border-top:.0625rem solid var(--sapPageFooter_BorderColor)}.fd-bar--floating-footer{height:2.5rem;background:var(--sapPageFooter_Background);box-shadow:var(--sapContent_Shadow1);border-radius:var(--sapElement_BorderCornerRadius);border:none;opacity:1;z-index:1000;position:absolute;bottom:0;left:0;right:0}.fd-bar--cozy,.fd-bar--cozy.fd-bar--header,.fd-bar--cozy.fd-bar--footer,.fd-bar--cozy.fd-bar--floating-footer{height:2.75rem}.fd-bar--cozy.fd-bar--subheader{height:3rem;padding-bottom:.25rem}.fd-bar--page,.fd-bar--home-page{padding:0 1rem}.fd-bar--page.fd-bar--floating-footer,.fd-bar--home-page.fd-bar--floating-footer{padding:0 .5rem;margin-top:.5rem;margin-bottom:.5rem;left:.5rem;right:.5rem}.fd-bar--page-s{padding:0 1rem}.fd-bar--page-s.fd-bar--floating-footer{padding:0 .5rem;margin-top:.5rem;margin-bottom:.5rem;left:1rem;right:1rem}.fd-bar--home-page-s{padding:0 .5rem}.fd-bar--home-page-s.fd-bar--floating-footer{padding:0 .5rem;margin-top:.5rem;margin-bottom:.5rem;left:1rem;right:1rem}.fd-bar--page-m_l,.fd-bar--home-page-m_l{padding:0 2rem}.fd-bar--page-m_l.fd-bar--floating-footer,.fd-bar--home-page-m_l.fd-bar--floating-footer{padding:0 .5rem;margin-top:.5rem;margin-bottom:.5rem;left:2rem;right:2rem}.fd-bar--page-xl,.fd-bar--home-page-xl{padding:0 3rem}.fd-bar--page-xl.fd-bar--floating-footer,.fd-bar--home-page-xl.fd-bar--floating-footer{padding:0 .5rem;margin-top:.5rem;margin-bottom:.5rem;left:3rem;right:3rem}\n"], changeDetection: i0.ChangeDetectionStrategy.OnPush, encapsulation: i0.ViewEncapsulation.None });
68
68
  __decorate([
69
69
  applyCssClass,
70
70
  __metadata("design:type", Function),
@@ -73,7 +73,7 @@ __decorate([
73
73
  ], BarComponent.prototype, "buildComponentCssClass", null);
74
74
  i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "13.2.4", ngImport: i0, type: BarComponent, decorators: [{
75
75
  type: Component,
76
- args: [{ selector: '[fd-bar]', encapsulation: ViewEncapsulation.None, changeDetection: ChangeDetectionStrategy.OnPush, template: "<ng-content select=\"[fd-bar-left]\"></ng-content>\n<ng-content select=\"[fd-bar-middle]\"></ng-content>\n<ng-content select=\"[fd-bar-right]\"></ng-content>\n<ng-content></ng-content>\n", styles: ["/*!\n * Fundamental Library Styles v0.24.1-rc.1\n * Copyright (c) 2022 SAP SE or an SAP affiliate company.\n * Licensed under Apache License 2.0 (https://github.com/SAP/fundamental-styles/blob/main/LICENSE)\n */.fd-bar{font-size:var(--sapFontSize);line-height:var(--sapContent_LineHeight);color:var(--sapTextColor);font-family:var(--sapFontFamily);font-weight:400;box-sizing:border-box;padding:0;margin:0;border:0;height:2.5rem;background:var(--sapPageHeader_Background);box-shadow:var(--sapContent_HeaderShadow);display:flex;flex-direction:row;justify-content:space-between;padding:0 1rem}.fd-bar:before,.fd-bar:after{box-sizing:inherit;font-size:inherit}.fd-bar__left,.fd-bar__middle,.fd-bar__right{font-size:var(--sapFontSize);line-height:var(--sapContent_LineHeight);color:var(--sapTextColor);font-family:var(--sapFontFamily);font-weight:400;box-sizing:border-box;padding:0;margin:0;border:0;display:flex;align-items:center;flex:1 1 auto;width:100%;max-width:100%}.fd-bar__left:before,.fd-bar__left:after,.fd-bar__middle:before,.fd-bar__middle:after,.fd-bar__right:before,.fd-bar__right:after{box-sizing:inherit;font-size:inherit}.fd-bar__middle{padding:0 var(--fdBar_Middle_Area_Padding_X);justify-content:center}.fd-bar__middle:only-child{padding:0}.fd-bar__left{padding-left:0;padding-right:var(--fdBar_Left_Area_Padding_Right)}[dir=rtl] .fd-bar__left,.fd-bar__left[dir=rtl]{padding-right:0;padding-left:var(--fdBar_Left_Area_Padding_Right)}.fd-bar__right{padding-left:--fdBar_Right_Area_Padding_Left;padding-right:0;justify-content:flex-end}[dir=rtl] .fd-bar__right,.fd-bar__right[dir=rtl]{padding-right:--fdBar_Right_Area_Padding_Left;padding-left:0}.fd-bar__element{font-size:var(--sapFontSize);line-height:var(--sapContent_LineHeight);color:var(--sapTextColor);font-family:var(--sapFontFamily);font-weight:400;box-sizing:border-box;padding:0;margin:0;border:0;display:flex;align-items:center;justify-content:center;margin-right:.5rem;max-width:100%;max-height:100%}.fd-bar__element:before,.fd-bar__element:after{box-sizing:inherit;font-size:inherit}[dir=rtl] .fd-bar__element,.fd-bar__element[dir=rtl]{margin-right:0;margin-left:.5rem}.fd-bar__element--full-width{width:100%}.fd-bar__element--full-width>*:first-child{flex-grow:1}.fd-bar__element:last-child{margin-right:0}[dir=rtl] .fd-bar__element:last-child,.fd-bar__element:last-child[dir=rtl]{margin-left:0;margin-right:0}.fd-bar--header{height:2.5rem;background:var(--sapPageHeader_Background);box-shadow:var(--sapContent_HeaderShadow);z-index:1}.fd-bar--subheader{height:2.25rem;background:var(--sapPageHeader_Background);box-shadow:var(--sapContent_HeaderShadow);padding-bottom:.25rem;z-index:1}.fd-bar--header-with-subheader{height:2.5rem;background:var(--sapPageHeader_Background);box-shadow:none;position:relative;z-index:2}.fd-bar--footer{height:2.5rem;background:var(--sapPageFooter_Background);box-shadow:none;border-top:.0625rem solid var(--sapPageFooter_BorderColor)}.fd-bar--floating-footer{height:2.5rem;background:var(--sapPageFooter_Background);box-shadow:var(--sapContent_Shadow1);border-radius:var(--sapElement_BorderCornerRadius);border:none;opacity:1;z-index:1000;position:absolute;bottom:0;left:0;right:0}.fd-bar--cozy,.fd-bar--cozy.fd-bar--header,.fd-bar--cozy.fd-bar--footer,.fd-bar--cozy.fd-bar--floating-footer{height:2.75rem}.fd-bar--cozy.fd-bar--subheader{height:3rem;padding-bottom:.25rem}.fd-bar--page,.fd-bar--home-page{padding:0 1rem}.fd-bar--page.fd-bar--floating-footer,.fd-bar--home-page.fd-bar--floating-footer{padding:0 .5rem;margin-top:.5rem;margin-bottom:.5rem;left:.5rem;right:.5rem}.fd-bar--page-s{padding:0 1rem}.fd-bar--page-s.fd-bar--floating-footer{padding:0 .5rem;margin-top:.5rem;margin-bottom:.5rem;left:1rem;right:1rem}.fd-bar--home-page-s{padding:0 .5rem}.fd-bar--home-page-s.fd-bar--floating-footer{padding:0 .5rem;margin-top:.5rem;margin-bottom:.5rem;left:1rem;right:1rem}.fd-bar--page-m_l,.fd-bar--home-page-m_l{padding:0 2rem}.fd-bar--page-m_l.fd-bar--floating-footer,.fd-bar--home-page-m_l.fd-bar--floating-footer{padding:0 .5rem;margin-top:.5rem;margin-bottom:.5rem;left:2rem;right:2rem}.fd-bar--page-xl,.fd-bar--home-page-xl{padding:0 3rem}.fd-bar--page-xl.fd-bar--floating-footer,.fd-bar--home-page-xl.fd-bar--floating-footer{padding:0 .5rem;margin-top:.5rem;margin-bottom:.5rem;left:3rem;right:3rem}.fd-bar--responsive-paddings{margin-top:.5rem;margin-bottom:.5rem}@media (max-width: 599px){.fd-bar--responsive-paddings{left:1rem;right:1rem}}@media (min-width: 600px) and (max-width: 1439px){.fd-bar--responsive-paddings{left:2rem;right:2rem}}@media (min-width: 1440px){.fd-bar--responsive-paddings{left:3rem;right:3rem}}\n"] }]
76
+ args: [{ selector: '[fd-bar]', encapsulation: ViewEncapsulation.None, changeDetection: ChangeDetectionStrategy.OnPush, template: "<ng-content select=\"[fd-bar-left]\"></ng-content>\n<ng-content select=\"[fd-bar-middle]\"></ng-content>\n<ng-content select=\"[fd-bar-right]\"></ng-content>\n<ng-content></ng-content>\n", styles: ["/*!\n * Fundamental Library Styles v0.24.1-rc.1\n * Copyright (c) 2022 SAP SE or an SAP affiliate company.\n * Licensed under Apache License 2.0 (https://github.com/SAP/fundamental-styles/blob/main/LICENSE)\n */.fd-bar{font-size:var(--sapFontSize);line-height:var(--sapContent_LineHeight);color:var(--sapTextColor);font-family:var(--sapFontFamily);font-weight:400;box-sizing:border-box;padding:0;margin:0;border:0;height:2.5rem;background:var(--sapPageHeader_Background);box-shadow:var(--sapContent_HeaderShadow);display:flex;flex-direction:row;justify-content:space-between;padding:0 1rem}.fd-bar:before,.fd-bar:after{box-sizing:inherit;font-size:inherit}.fd-bar__left,.fd-bar__middle,.fd-bar__right{font-size:var(--sapFontSize);line-height:var(--sapContent_LineHeight);color:var(--sapTextColor);font-family:var(--sapFontFamily);font-weight:400;box-sizing:border-box;padding:0;margin:0;border:0;display:flex;align-items:center;flex:1 1 auto;width:100%;max-width:100%}.fd-bar__left:before,.fd-bar__left:after,.fd-bar__middle:before,.fd-bar__middle:after,.fd-bar__right:before,.fd-bar__right:after{box-sizing:inherit;font-size:inherit}.fd-bar__middle{padding:0 var(--fdBar_Middle_Area_Padding_X);justify-content:center}.fd-bar__middle:only-child{padding:0}.fd-bar__left{padding-left:0;padding-right:var(--fdBar_Left_Area_Padding_Right)}[dir=rtl] .fd-bar__left,.fd-bar__left[dir=rtl]{padding-right:0;padding-left:var(--fdBar_Left_Area_Padding_Right)}.fd-bar__right{padding-left:--fdBar_Right_Area_Padding_Left;padding-right:0;justify-content:flex-end}[dir=rtl] .fd-bar__right,.fd-bar__right[dir=rtl]{padding-right:--fdBar_Right_Area_Padding_Left;padding-left:0}.fd-bar__element{font-size:var(--sapFontSize);line-height:var(--sapContent_LineHeight);color:var(--sapTextColor);font-family:var(--sapFontFamily);font-weight:400;box-sizing:border-box;padding:0;margin:0;border:0;display:flex;align-items:center;justify-content:center;margin-right:.5rem;max-width:100%;max-height:100%}.fd-bar__element:before,.fd-bar__element:after{box-sizing:inherit;font-size:inherit}[dir=rtl] .fd-bar__element,.fd-bar__element[dir=rtl]{margin-right:0;margin-left:.5rem}.fd-bar__element--full-width{width:100%}.fd-bar__element--full-width>*:first-child{flex-grow:1}.fd-bar__element:last-child{margin-right:0}[dir=rtl] .fd-bar__element:last-child,.fd-bar__element:last-child[dir=rtl]{margin-left:0;margin-right:0}.fd-bar--header{height:2.5rem;background:var(--sapPageHeader_Background);box-shadow:var(--sapContent_HeaderShadow);z-index:1}.fd-bar--subheader{height:2.25rem;background:var(--sapPageHeader_Background);box-shadow:var(--sapContent_HeaderShadow);padding-bottom:.25rem;z-index:1}.fd-bar--header-with-subheader{height:2.5rem;background:var(--sapPageHeader_Background);box-shadow:none;position:relative;z-index:2}.fd-bar--footer{height:2.5rem;background:var(--sapPageFooter_Background);box-shadow:none;border-top:.0625rem solid var(--sapPageFooter_BorderColor)}.fd-bar--floating-footer{height:2.5rem;background:var(--sapPageFooter_Background);box-shadow:var(--sapContent_Shadow1);border-radius:var(--sapElement_BorderCornerRadius);border:none;opacity:1;z-index:1000;position:absolute;bottom:0;left:0;right:0}.fd-bar--cozy,.fd-bar--cozy.fd-bar--header,.fd-bar--cozy.fd-bar--footer,.fd-bar--cozy.fd-bar--floating-footer{height:2.75rem}.fd-bar--cozy.fd-bar--subheader{height:3rem;padding-bottom:.25rem}.fd-bar--page,.fd-bar--home-page{padding:0 1rem}.fd-bar--page.fd-bar--floating-footer,.fd-bar--home-page.fd-bar--floating-footer{padding:0 .5rem;margin-top:.5rem;margin-bottom:.5rem;left:.5rem;right:.5rem}.fd-bar--page-s{padding:0 1rem}.fd-bar--page-s.fd-bar--floating-footer{padding:0 .5rem;margin-top:.5rem;margin-bottom:.5rem;left:1rem;right:1rem}.fd-bar--home-page-s{padding:0 .5rem}.fd-bar--home-page-s.fd-bar--floating-footer{padding:0 .5rem;margin-top:.5rem;margin-bottom:.5rem;left:1rem;right:1rem}.fd-bar--page-m_l,.fd-bar--home-page-m_l{padding:0 2rem}.fd-bar--page-m_l.fd-bar--floating-footer,.fd-bar--home-page-m_l.fd-bar--floating-footer{padding:0 .5rem;margin-top:.5rem;margin-bottom:.5rem;left:2rem;right:2rem}.fd-bar--page-xl,.fd-bar--home-page-xl{padding:0 3rem}.fd-bar--page-xl.fd-bar--floating-footer,.fd-bar--home-page-xl.fd-bar--floating-footer{padding:0 .5rem;margin-top:.5rem;margin-bottom:.5rem;left:3rem;right:3rem}\n"] }]
77
77
  }], ctorParameters: function () {
78
78
  return [{ type: i0.ElementRef }, { type: i1.ContentDensityService, decorators: [{
79
79
  type: Optional
@@ -8,7 +8,7 @@ import * as i1 from '@fundamental-ngx/core/utils';
8
8
  import { resizeObservable, DragAndDropModule } from '@fundamental-ngx/core/utils';
9
9
  import { FocusKeyManager } from '@angular/cdk/a11y';
10
10
  import { Subject } from 'rxjs';
11
- import { takeUntil, debounceTime } from 'rxjs/operators';
11
+ import { takeUntil, debounceTime, delay } from 'rxjs/operators';
12
12
  import { coerceNumberProperty } from '@angular/cdk/coercion';
13
13
 
14
14
  class FixedCardLayoutItemComponent {
@@ -165,14 +165,6 @@ class FixedCardLayoutComponent {
165
165
  this._accessibilitySetup();
166
166
  }
167
167
  /** @hidden */
168
- ngAfterViewChecked() {
169
- /**
170
- * Update column layout when orientation of screen changes.
171
- * actual width is returned when view is stable. In AfterViewInit, correct value does not come.
172
- */
173
- this.updateLayout();
174
- }
175
- /** @hidden */
176
168
  ngOnChanges(changes) {
177
169
  var _a;
178
170
  if (!((_a = this._cards) === null || _a === void 0 ? void 0 : _a.length)) {
@@ -199,7 +191,7 @@ class FixedCardLayoutComponent {
199
191
  }
200
192
  /** Distribute cards on window resize */
201
193
  updateLayout() {
202
- if (!this._cards.length) {
194
+ if (!this._cards.length || !this._availableWidth) {
203
195
  return;
204
196
  }
205
197
  const possibleNumberOfColumns = getNumberOfColumns(this._availableWidth, this.cardMinimumWidth);
@@ -215,19 +207,6 @@ class FixedCardLayoutComponent {
215
207
  }
216
208
  this._setColumnsWidth();
217
209
  }
218
- /** @hidden Calculate container height basing on the card wrapper columns */
219
- _calculateContainerHeight(additionalSpace = 0) {
220
- this._changeDetector.detectChanges();
221
- const wrapperColumns = this._cardColumns.map((column) => column
222
- .map((card) => { var _a; return (_a = this._cardWrappers.find((wrapper) => wrapper.getSortedItems()[0].data === card)) === null || _a === void 0 ? void 0 : _a.element; })
223
- .filter((v) => !!v));
224
- const columnsHeights = wrapperColumns
225
- .map((column) => column.map((card) => card.nativeElement.getBoundingClientRect().height))
226
- .map((column) => column.reduce((height, cardHeight) => (height += cardHeight), 0));
227
- // +4px because it's the top & bottom borders of card placeholder
228
- this._containerHeight = Math.max(...columnsHeights) + 4 + additionalSpace;
229
- this._changeDetector.detectChanges();
230
- }
231
210
  /** @hidden */
232
211
  _onDropListExited() {
233
212
  this._shouldCalculateContainerHeight = true;
@@ -299,7 +278,7 @@ class FixedCardLayoutComponent {
299
278
  }
300
279
  /** @hidden Listen card change and distribute cards on column change */
301
280
  _listenOnCardsChange() {
302
- this._cards.changes.subscribe(() => {
281
+ this._cards.changes.pipe(delay(0)).subscribe(() => {
303
282
  this._processCards();
304
283
  this._updateColumns();
305
284
  });
@@ -315,7 +294,6 @@ class FixedCardLayoutComponent {
315
294
  this._cardsArray = this._cards
316
295
  .toArray()
317
296
  .sort((firstCard, secondCard) => firstCard.fdCardDef - secondCard.fdCardDef);
318
- this._changeDetector.detectChanges();
319
297
  this.updateLayout();
320
298
  }
321
299
  /** @hidden Distribute cards among columns to arrange them in "Z" flow */
@@ -358,6 +336,19 @@ class FixedCardLayoutComponent {
358
336
  this._changeDetector.detectChanges();
359
337
  }
360
338
  }
339
+ /** @hidden Calculate container height basing on the card wrapper columns */
340
+ _calculateContainerHeight(additionalSpace = 0) {
341
+ this._changeDetector.detectChanges();
342
+ const wrapperColumns = this._cardColumns.map((column) => column
343
+ .map((card) => { var _a; return (_a = this._cardWrappers.find((wrapper) => wrapper.getSortedItems()[0].data === card)) === null || _a === void 0 ? void 0 : _a.element; })
344
+ .filter((v) => !!v));
345
+ const columnsHeights = wrapperColumns
346
+ .map((column) => column.map((card) => card.nativeElement.getBoundingClientRect().height))
347
+ .map((column) => column.reduce((height, cardHeight) => (height += cardHeight), 0));
348
+ // +4px because it's the top & bottom borders of card placeholder
349
+ this._containerHeight = Math.max(...columnsHeights) + 4 + additionalSpace;
350
+ this._changeDetector.detectChanges();
351
+ }
361
352
  }
362
353
  FixedCardLayoutComponent.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "13.2.4", ngImport: i0, type: FixedCardLayoutComponent, deps: [{ token: i0.ChangeDetectorRef }, { token: i1.RtlService, optional: true }], target: i0.ɵɵFactoryTarget.Component });
363
354
  FixedCardLayoutComponent.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "12.0.0", version: "13.2.4", type: FixedCardLayoutComponent, selector: "fd-fixed-card-layout", inputs: { disableDragDrop: "disableDragDrop", dragStartDelay: "dragStartDelay", cardMinimumWidth: "cardMinimumWidth", columnsWidthConfig: "columnsWidthConfig", maxColumns: "maxColumns" }, outputs: { layoutChange: "layoutChange", cardDraggedDropped: "cardDraggedDropped" }, host: { listeners: { "keydown": "handleKeydown($event)" }, classAttribute: "fd-fixed-card-layout" }, queries: [{ propertyName: "_cards", predicate: CardDefinitionDirective }], viewQueries: [{ propertyName: "_layout", first: true, predicate: ["layout"], descendants: true }, { propertyName: "_cardContainers", predicate: FixedCardLayoutItemComponent, descendants: true }, { propertyName: "_cardWrappers", predicate: ["dropList"], descendants: true, read: CdkDropList }], usesOnChanges: true, ngImport: i0, template: "<div\n #layout\n cdkDropListGroup\n fdDndKeyboardGroup\n class=\"fd-fixed-card-layout__card-layout fd-fixed-card-layout__card-layout--columns-{{ this._numberOfColumns }}\"\n [style.height]=\"_containerHeight + 'px'\"\n [groups]=\"_cardColumns\"\n orientation=\"horizontal\"\n [customMoveFn]=\"_customMoveFn\"\n [customTransferFn]=\"_customTransferFn\"\n [disableKeyboardDragDrop]=\"disableDragDrop\"\n [cdkDropListGroupDisabled]=\"disableDragDrop\"\n [attr.dir]=\"_dir\"\n>\n <div\n #dropList\n *ngFor=\"let card of _cardsArray; let cardIndex = index\"\n cdkDropList\n cdkDropListSortingDisabled\n class=\"fd-fixed-card-layout__card\"\n [class.fd-fixed-card-layout__card--single]=\"_singleItemColumns.has(card.fdCardDef)\"\n [style.min-width.px]=\"_columnsWidth.get(card.fdCardDef)\"\n [style.max-width.px]=\"_columnsWidth.get(card.fdCardDef)\"\n [cdkDropListData]=\"cardIndex\"\n [cdkDropListEnterPredicate]=\"_enterPredicate\"\n (cdkDropListEntered)=\"_onDropListEntered($event)\"\n (cdkDropListExited)=\"_onDropListExited()\"\n >\n <div\n cdkDrag\n fdDndKeyboardItem\n tabindex=\"0\"\n cdkDragPreviewClass=\"fd-fixed-card-layout__card-preview\"\n [cdkDragData]=\"card\"\n [cdkDragStartDelay]=\"dragStartDelay\"\n [itemIndex]=\"_itemIndexes.get(card.fdCardDef)!\"\n [groupIndex]=\"_groupIndexes.get(card.fdCardDef)!\"\n (cdkDragDropped)=\"_onDragDropped($event)\"\n (cdkDragStarted)=\"_setPlaceholderStyle(false)\"\n >\n <fd-fixed-card-layout-item>\n <ng-container *ngTemplateOutlet=\"card?.template || null\"> </ng-container>\n </fd-fixed-card-layout-item>\n\n <div *cdkDragPlaceholder class=\"fd-fixed-card-layout__card-placeholder\" [style]=\"_placeholderMargin\">\n <ng-container *ngTemplateOutlet=\"card?.template || null\"></ng-container>\n </div>\n </div>\n </div>\n\n <ng-container *ngFor=\"let column of _cardColumns; let last = last; let index = index\">\n <div *ngIf=\"!last\" class=\"fd-fixed-card-layout__clearfix\" [style.order]=\"index + 1\"></div>\n </ng-container>\n</div>\n", styles: ["/*!\n * Fundamental Library Styles v0.24.1-rc.1\n * Copyright (c) 2022 SAP SE or an SAP affiliate company.\n * Licensed under Apache License 2.0 (https://github.com/SAP/fundamental-styles/blob/main/LICENSE)\n */.fd-fixed-card-layout{font-size:var(--sapFontSize);line-height:var(--sapContent_LineHeight);color:var(--sapTextColor);font-family:var(--sapFontFamily);font-weight:400;box-sizing:border-box;padding:0;margin:0;border:0}.fd-fixed-card-layout:before,.fd-fixed-card-layout:after{box-sizing:inherit;font-size:inherit}.fd-fixed-card-layout__card-layout{font-size:var(--sapFontSize);line-height:var(--sapContent_LineHeight);color:var(--sapTextColor);font-family:var(--sapFontFamily);font-weight:400;box-sizing:border-box;padding:0;margin:0;border:0;margin-left:-1rem;display:flex;justify-content:flex-start;align-items:center;flex-wrap:wrap;flex-direction:column;margin-top:-1rem}.fd-fixed-card-layout__card-layout:before,.fd-fixed-card-layout__card-layout:after{box-sizing:inherit;font-size:inherit}[dir=rtl] .fd-fixed-card-layout__card-layout,.fd-fixed-card-layout__card-layout[dir=rtl]{margin-right:-1rem;margin-left:0}.fd-fixed-card-layout__card-layout.fd-fixed-card-layout__card-layout--columns-2 .fd-fixed-card-layout__card{width:50%}.fd-fixed-card-layout__card-layout.fd-fixed-card-layout__card-layout--columns-2 .fd-fixed-card-layout__card:nth-of-type(2n){order:2}.fd-fixed-card-layout__card-layout.fd-fixed-card-layout__card-layout--columns-2 .fd-fixed-card-layout__card:nth-of-type(2n + 1){order:1}.fd-fixed-card-layout__card-layout.fd-fixed-card-layout__card-layout--columns-3 .fd-fixed-card-layout__card{width:33.3333333333%}.fd-fixed-card-layout__card-layout.fd-fixed-card-layout__card-layout--columns-3 .fd-fixed-card-layout__card:nth-of-type(3n){order:3}.fd-fixed-card-layout__card-layout.fd-fixed-card-layout__card-layout--columns-3 .fd-fixed-card-layout__card:nth-of-type(3n + 1){order:1}.fd-fixed-card-layout__card-layout.fd-fixed-card-layout__card-layout--columns-3 .fd-fixed-card-layout__card:nth-of-type(3n + 2){order:2}.fd-fixed-card-layout__card-layout.fd-fixed-card-layout__card-layout--columns-4 .fd-fixed-card-layout__card{width:25%}.fd-fixed-card-layout__card-layout.fd-fixed-card-layout__card-layout--columns-4 .fd-fixed-card-layout__card:nth-of-type(4n){order:4}.fd-fixed-card-layout__card-layout.fd-fixed-card-layout__card-layout--columns-4 .fd-fixed-card-layout__card:nth-of-type(4n + 1){order:1}.fd-fixed-card-layout__card-layout.fd-fixed-card-layout__card-layout--columns-4 .fd-fixed-card-layout__card:nth-of-type(4n + 2){order:2}.fd-fixed-card-layout__card-layout.fd-fixed-card-layout__card-layout--columns-4 .fd-fixed-card-layout__card:nth-of-type(4n + 3){order:3}.fd-fixed-card-layout__card-layout.fd-fixed-card-layout__card-layout--columns-5 .fd-fixed-card-layout__card{width:20%}.fd-fixed-card-layout__card-layout.fd-fixed-card-layout__card-layout--columns-5 .fd-fixed-card-layout__card:nth-of-type(5n){order:5}.fd-fixed-card-layout__card-layout.fd-fixed-card-layout__card-layout--columns-5 .fd-fixed-card-layout__card:nth-of-type(5n + 1){order:1}.fd-fixed-card-layout__card-layout.fd-fixed-card-layout__card-layout--columns-5 .fd-fixed-card-layout__card:nth-of-type(5n + 2){order:2}.fd-fixed-card-layout__card-layout.fd-fixed-card-layout__card-layout--columns-5 .fd-fixed-card-layout__card:nth-of-type(5n + 3){order:3}.fd-fixed-card-layout__card-layout.fd-fixed-card-layout__card-layout--columns-5 .fd-fixed-card-layout__card:nth-of-type(5n + 4){order:4}.fd-fixed-card-layout__card-layout.fd-fixed-card-layout__card-layout--columns-6 .fd-fixed-card-layout__card{width:16.6666666667%}.fd-fixed-card-layout__card-layout.fd-fixed-card-layout__card-layout--columns-6 .fd-fixed-card-layout__card:nth-of-type(6n){order:6}.fd-fixed-card-layout__card-layout.fd-fixed-card-layout__card-layout--columns-6 .fd-fixed-card-layout__card:nth-of-type(6n + 1){order:1}.fd-fixed-card-layout__card-layout.fd-fixed-card-layout__card-layout--columns-6 .fd-fixed-card-layout__card:nth-of-type(6n + 2){order:2}.fd-fixed-card-layout__card-layout.fd-fixed-card-layout__card-layout--columns-6 .fd-fixed-card-layout__card:nth-of-type(6n + 3){order:3}.fd-fixed-card-layout__card-layout.fd-fixed-card-layout__card-layout--columns-6 .fd-fixed-card-layout__card:nth-of-type(6n + 4){order:4}.fd-fixed-card-layout__card-layout.fd-fixed-card-layout__card-layout--columns-6 .fd-fixed-card-layout__card:nth-of-type(6n + 5){order:5}.fd-fixed-card-layout__card-layout.fd-fixed-card-layout__card-layout--columns-7 .fd-fixed-card-layout__card{width:14.2857142857%}.fd-fixed-card-layout__card-layout.fd-fixed-card-layout__card-layout--columns-7 .fd-fixed-card-layout__card:nth-of-type(7n){order:7}.fd-fixed-card-layout__card-layout.fd-fixed-card-layout__card-layout--columns-7 .fd-fixed-card-layout__card:nth-of-type(7n + 1){order:1}.fd-fixed-card-layout__card-layout.fd-fixed-card-layout__card-layout--columns-7 .fd-fixed-card-layout__card:nth-of-type(7n + 2){order:2}.fd-fixed-card-layout__card-layout.fd-fixed-card-layout__card-layout--columns-7 .fd-fixed-card-layout__card:nth-of-type(7n + 3){order:3}.fd-fixed-card-layout__card-layout.fd-fixed-card-layout__card-layout--columns-7 .fd-fixed-card-layout__card:nth-of-type(7n + 4){order:4}.fd-fixed-card-layout__card-layout.fd-fixed-card-layout__card-layout--columns-7 .fd-fixed-card-layout__card:nth-of-type(7n + 5){order:5}.fd-fixed-card-layout__card-layout.fd-fixed-card-layout__card-layout--columns-7 .fd-fixed-card-layout__card:nth-of-type(7n + 6){order:6}.fd-fixed-card-layout__card-layout.fd-fixed-card-layout__card-layout--columns-8 .fd-fixed-card-layout__card{width:12.5%}.fd-fixed-card-layout__card-layout.fd-fixed-card-layout__card-layout--columns-8 .fd-fixed-card-layout__card:nth-of-type(8n){order:8}.fd-fixed-card-layout__card-layout.fd-fixed-card-layout__card-layout--columns-8 .fd-fixed-card-layout__card:nth-of-type(8n + 1){order:1}.fd-fixed-card-layout__card-layout.fd-fixed-card-layout__card-layout--columns-8 .fd-fixed-card-layout__card:nth-of-type(8n + 2){order:2}.fd-fixed-card-layout__card-layout.fd-fixed-card-layout__card-layout--columns-8 .fd-fixed-card-layout__card:nth-of-type(8n + 3){order:3}.fd-fixed-card-layout__card-layout.fd-fixed-card-layout__card-layout--columns-8 .fd-fixed-card-layout__card:nth-of-type(8n + 4){order:4}.fd-fixed-card-layout__card-layout.fd-fixed-card-layout__card-layout--columns-8 .fd-fixed-card-layout__card:nth-of-type(8n + 5){order:5}.fd-fixed-card-layout__card-layout.fd-fixed-card-layout__card-layout--columns-8 .fd-fixed-card-layout__card:nth-of-type(8n + 6){order:6}.fd-fixed-card-layout__card-layout.fd-fixed-card-layout__card-layout--columns-8 .fd-fixed-card-layout__card:nth-of-type(8n + 7){order:7}.fd-fixed-card-layout__card-layout.fd-fixed-card-layout__card-layout--columns-9 .fd-fixed-card-layout__card{width:11.1111111111%}.fd-fixed-card-layout__card-layout.fd-fixed-card-layout__card-layout--columns-9 .fd-fixed-card-layout__card:nth-of-type(9n){order:9}.fd-fixed-card-layout__card-layout.fd-fixed-card-layout__card-layout--columns-9 .fd-fixed-card-layout__card:nth-of-type(9n + 1){order:1}.fd-fixed-card-layout__card-layout.fd-fixed-card-layout__card-layout--columns-9 .fd-fixed-card-layout__card:nth-of-type(9n + 2){order:2}.fd-fixed-card-layout__card-layout.fd-fixed-card-layout__card-layout--columns-9 .fd-fixed-card-layout__card:nth-of-type(9n + 3){order:3}.fd-fixed-card-layout__card-layout.fd-fixed-card-layout__card-layout--columns-9 .fd-fixed-card-layout__card:nth-of-type(9n + 4){order:4}.fd-fixed-card-layout__card-layout.fd-fixed-card-layout__card-layout--columns-9 .fd-fixed-card-layout__card:nth-of-type(9n + 5){order:5}.fd-fixed-card-layout__card-layout.fd-fixed-card-layout__card-layout--columns-9 .fd-fixed-card-layout__card:nth-of-type(9n + 6){order:6}.fd-fixed-card-layout__card-layout.fd-fixed-card-layout__card-layout--columns-9 .fd-fixed-card-layout__card:nth-of-type(9n + 7){order:7}.fd-fixed-card-layout__card-layout.fd-fixed-card-layout__card-layout--columns-9 .fd-fixed-card-layout__card:nth-of-type(9n + 8){order:8}.fd-fixed-card-layout__card-layout.fd-fixed-card-layout__card-layout--columns-10 .fd-fixed-card-layout__card{width:10%}.fd-fixed-card-layout__card-layout.fd-fixed-card-layout__card-layout--columns-10 .fd-fixed-card-layout__card:nth-of-type(10n){order:10}.fd-fixed-card-layout__card-layout.fd-fixed-card-layout__card-layout--columns-10 .fd-fixed-card-layout__card:nth-of-type(10n + 1){order:1}.fd-fixed-card-layout__card-layout.fd-fixed-card-layout__card-layout--columns-10 .fd-fixed-card-layout__card:nth-of-type(10n + 2){order:2}.fd-fixed-card-layout__card-layout.fd-fixed-card-layout__card-layout--columns-10 .fd-fixed-card-layout__card:nth-of-type(10n + 3){order:3}.fd-fixed-card-layout__card-layout.fd-fixed-card-layout__card-layout--columns-10 .fd-fixed-card-layout__card:nth-of-type(10n + 4){order:4}.fd-fixed-card-layout__card-layout.fd-fixed-card-layout__card-layout--columns-10 .fd-fixed-card-layout__card:nth-of-type(10n + 5){order:5}.fd-fixed-card-layout__card-layout.fd-fixed-card-layout__card-layout--columns-10 .fd-fixed-card-layout__card:nth-of-type(10n + 6){order:6}.fd-fixed-card-layout__card-layout.fd-fixed-card-layout__card-layout--columns-10 .fd-fixed-card-layout__card:nth-of-type(10n + 7){order:7}.fd-fixed-card-layout__card-layout.fd-fixed-card-layout__card-layout--columns-10 .fd-fixed-card-layout__card:nth-of-type(10n + 8){order:8}.fd-fixed-card-layout__card-layout.fd-fixed-card-layout__card-layout--columns-10 .fd-fixed-card-layout__card:nth-of-type(10n + 9){order:9}.fd-fixed-card-layout__card,.fd-fixed-card-layout__card-placeholder{font-size:var(--sapFontSize);line-height:var(--sapContent_LineHeight);color:var(--sapTextColor);font-family:var(--sapFontFamily);font-weight:400;box-sizing:border-box;padding:0;margin:0;border:0;min-width:20rem;min-height:.0625rem}.fd-fixed-card-layout__card:before,.fd-fixed-card-layout__card:after,.fd-fixed-card-layout__card-placeholder:before,.fd-fixed-card-layout__card-placeholder:after{box-sizing:inherit;font-size:inherit}.fd-fixed-card-layout__card{padding-left:1rem;order:1;padding-top:1rem}[dir=rtl] .fd-fixed-card-layout__card,.fd-fixed-card-layout__card[dir=rtl]{padding-right:1rem;padding-left:0}.fd-fixed-card-layout__card--single{flex-basis:100%}.fd-fixed-card-layout__card:empty{padding-top:0}.fd-fixed-card-layout__card-placeholder{opacity:.3;border:.125rem dashed var(--sapContent_DragAndDropActiveColor);cursor:grabbing}.fd-fixed-card-layout__card-preview{font-size:var(--sapFontSize);line-height:var(--sapContent_LineHeight);color:var(--sapTextColor);font-family:var(--sapFontFamily);font-weight:400;padding:0;margin:0;border:0;box-sizing:border-box;border-radius:var(--sapElement_BorderCornerRadius);box-shadow:var(--sapContent_Shadow2)}.fd-fixed-card-layout__card-preview:before,.fd-fixed-card-layout__card-preview:after{box-sizing:inherit;font-size:inherit}.fd-fixed-card-layout__clearfix{font-size:var(--sapFontSize);line-height:var(--sapContent_LineHeight);color:var(--sapTextColor);font-family:var(--sapFontFamily);font-weight:400;box-sizing:border-box;padding:0;margin:0;border:0;width:0;flex-basis:100%}.fd-fixed-card-layout__clearfix:before,.fd-fixed-card-layout__clearfix:after{box-sizing:inherit;font-size:inherit}.fd-fixed-card-layout__card{width:100%}.fd-fixed-card-layout__card-placeholder{width:100%;min-width:100%;max-width:100%}\n"], components: [{ type: FixedCardLayoutItemComponent, selector: "fd-fixed-card-layout-item" }], directives: [{ type: i3.CdkDropListGroup, selector: "[cdkDropListGroup]", inputs: ["cdkDropListGroupDisabled"], exportAs: ["cdkDropListGroup"] }, { type: i1.DndKeyboardGroupDirective, selector: "[fdDndKeyboardGroup]", inputs: ["groups", "disableKeyboardDragDrop", "orientation", "customMoveFn", "customTransferFn"] }, { type: i4.NgForOf, selector: "[ngFor][ngForOf]", inputs: ["ngForOf", "ngForTrackBy", "ngForTemplate"] }, { type: i3.CdkDropList, selector: "[cdkDropList], cdk-drop-list", inputs: ["cdkDropListConnectedTo", "cdkDropListData", "cdkDropListOrientation", "id", "cdkDropListLockAxis", "cdkDropListDisabled", "cdkDropListSortingDisabled", "cdkDropListEnterPredicate", "cdkDropListSortPredicate", "cdkDropListAutoScrollDisabled", "cdkDropListAutoScrollStep"], outputs: ["cdkDropListDropped", "cdkDropListEntered", "cdkDropListExited", "cdkDropListSorted"], exportAs: ["cdkDropList"] }, { type: i3.CdkDrag, selector: "[cdkDrag]", inputs: ["cdkDragData", "cdkDragLockAxis", "cdkDragRootElement", "cdkDragBoundary", "cdkDragStartDelay", "cdkDragFreeDragPosition", "cdkDragDisabled", "cdkDragConstrainPosition", "cdkDragPreviewClass", "cdkDragPreviewContainer"], outputs: ["cdkDragStarted", "cdkDragReleased", "cdkDragEnded", "cdkDragEntered", "cdkDragExited", "cdkDragDropped", "cdkDragMoved"], exportAs: ["cdkDrag"] }, { type: i1.DndKeyboardItemDirective, selector: "[fdDndKeyboardItem]", inputs: ["itemIndex", "groupIndex"] }, { type: i4.NgTemplateOutlet, selector: "[ngTemplateOutlet]", inputs: ["ngTemplateOutletContext", "ngTemplateOutlet"] }, { type: i3.CdkDragPlaceholder, selector: "ng-template[cdkDragPlaceholder]", inputs: ["data"] }, { type: i4.NgIf, selector: "[ngIf]", inputs: ["ngIf", "ngIfThen", "ngIfElse"] }], changeDetection: i0.ChangeDetectionStrategy.OnPush, encapsulation: i0.ViewEncapsulation.None });
@@ -1 +1 @@
1
- {"version":3,"file":"fundamental-ngx-core-fixed-card-layout.mjs","sources":["../../../../libs/core/src/lib/fixed-card-layout/fixed-card-layout-item/fixed-card-layout-item.component.ts","../../../../libs/core/src/lib/fixed-card-layout/fixed-card-layout.component.ts","../../../../libs/core/src/lib/fixed-card-layout/fixed-card-layout.component.html","../../../../libs/core/src/lib/fixed-card-layout/fixed-card-layout.module.ts","../../../../libs/core/src/lib/fixed-card-layout/fundamental-ngx-core-fixed-card-layout.ts"],"sourcesContent":["import { ChangeDetectionStrategy, Component, ElementRef } from '@angular/core';\nimport { FocusableOption } from '@angular/cdk/a11y';\n\n@Component({\n selector: 'fd-fixed-card-layout-item',\n template: `<ng-content></ng-content>`,\n changeDetection: ChangeDetectionStrategy.OnPush,\n host: {\n style: 'display: block'\n }\n})\nexport class FixedCardLayoutItemComponent implements FocusableOption {\n constructor(private _elementRef: ElementRef) {}\n\n /** Set focus on the element. */\n focus(): void {\n const header = this._elementRef.nativeElement.querySelector('.fd-card__header');\n if (header) {\n header.focus();\n }\n }\n}\n","import {\n AfterContentInit,\n AfterViewChecked,\n AfterViewInit,\n ChangeDetectionStrategy,\n ChangeDetectorRef,\n Component,\n ContentChildren,\n Directive,\n ElementRef,\n EventEmitter,\n HostListener,\n Input,\n OnChanges,\n OnDestroy,\n OnInit,\n Optional,\n Output,\n QueryList,\n SimpleChanges,\n TemplateRef,\n ViewChild,\n ViewChildren,\n ViewEncapsulation\n} from '@angular/core';\nimport { FocusKeyManager } from '@angular/cdk/a11y';\nimport { CdkDrag, CdkDragDrop, CdkDragEnter, CdkDropList } from '@angular/cdk/drag-drop';\nimport { Subject } from 'rxjs';\nimport { debounceTime, takeUntil } from 'rxjs/operators';\n\nimport { resizeObservable, RtlService } from '@fundamental-ngx/core/utils';\nimport { FixedCardLayoutItemComponent } from './fixed-card-layout-item/fixed-card-layout-item.component';\nimport { coerceNumberProperty, NumberInput } from '@angular/cdk/coercion';\n\nconst PX_IN_REM = 16;\nconst CARD_MINIMUM_WIDTH = 320; // 320px = 20rem\nconst CARD_GAP_WIDTH = 16; // 16px = 1rem\nconst DRAG_START_DELAY = 200; // in ms\nconst MAX_COLUMNS = 10;\n\nlet cardRank = 1;\n\n@Directive({ selector: '[fdCardDef]' })\nexport class CardDefinitionDirective {\n /**\n * Behaves like rank of card.\n * Useful in creating layout again after drag and drop.\n */\n @Input()\n set fdCardDef(value: NumberInput) {\n if (!value) {\n return;\n }\n\n this._fdCardDef = coerceNumberProperty(value);\n }\n get fdCardDef(): number {\n return this._fdCardDef;\n }\n\n /** @hidden */\n private _fdCardDef: number = cardRank++;\n\n /** @hidden */\n constructor(public template: TemplateRef<any>) {}\n}\n\nexport interface Layout {\n numberOfColumns?: number;\n screenSize: number;\n}\n\nexport interface CardDropped {\n previousIndex: number;\n currentIndex: number;\n layoutColumns: number;\n items: CardDefinitionDirective[];\n}\n\ntype Columns = 1 | 2 | 3 | 4 | 5 | 6 | 7 | 8 | 9 | 10;\n\nexport type ColumnsWidthConfig = { [C in Columns]?: number };\n\ntype CardColumn = CardDefinitionDirective[];\n\n@Component({\n selector: 'fd-fixed-card-layout',\n templateUrl: './fixed-card-layout.component.html',\n styleUrls: ['./fixed-card-layout.component.scss'],\n changeDetection: ChangeDetectionStrategy.OnPush,\n encapsulation: ViewEncapsulation.None,\n host: {\n class: 'fd-fixed-card-layout'\n }\n})\nexport class FixedCardLayoutComponent\n implements OnInit, AfterContentInit, AfterViewInit, AfterViewChecked, OnChanges, OnDestroy\n{\n /** Drag drop behavior can be disabled */\n @Input()\n disableDragDrop: boolean;\n\n /** Drag start delay in milliseconds, default to 200ms for safe scrolling on mobile with touchscreen */\n @Input()\n dragStartDelay = DRAG_START_DELAY;\n\n /** Card's minimum width in pixels. */\n @Input()\n set cardMinimumWidth(value: NumberInput) {\n const coercedValue = coerceNumberProperty(value);\n\n if (coercedValue < CARD_MINIMUM_WIDTH) {\n return;\n }\n\n this._cardMinimumWidth = coercedValue;\n\n // If component is ready, do the recalculation.\n if (this._layout) {\n this.updateLayout();\n }\n }\n get cardMinimumWidth(): number {\n return this._cardMinimumWidth;\n }\n\n /** Config with the width ratios that should take every column. Flex-grow principe. Missed values set to 0. s*/\n @Input()\n columnsWidthConfig: ColumnsWidthConfig;\n\n /** Limit the number of columns. Default is 10. */\n @Input()\n maxColumns = MAX_COLUMNS;\n\n /** Event to emit, when layout changes */\n @Output()\n layoutChange: EventEmitter<Layout> = new EventEmitter<Layout>();\n\n /** Event to emit on Card dragged and dropped */\n @Output()\n cardDraggedDropped: EventEmitter<CardDropped> = new EventEmitter<CardDropped>();\n\n /** @hidden */\n @ContentChildren(CardDefinitionDirective)\n _cards: QueryList<CardDefinitionDirective>;\n\n /** @hidden */\n @ViewChildren(FixedCardLayoutItemComponent)\n _cardContainers: QueryList<FixedCardLayoutItemComponent>;\n\n /** @hidden */\n @ViewChildren('dropList', { read: CdkDropList })\n _cardWrappers: QueryList<CdkDropList>;\n\n /** @hidden */\n @ViewChild('layout')\n _layout: ElementRef;\n\n /** @hidden */\n _cardsArray: Array<CardDefinitionDirective>;\n\n /** @hidden Number of Columns in layout */\n _numberOfColumns: number;\n\n /** @hidden */\n _cardColumns: CardColumn[];\n\n /** @hidden*/\n _containerHeight: number;\n\n /** @hidden handles rtl service */\n _dir = 'ltr';\n\n /** @hidden first number is the CardDefinition rank, i.e. id */\n _groupIndexes = new Map<number, number>();\n\n /** @hidden first number is the CardDefinition rank, i.e. id */\n _itemIndexes = new Map<number, number>();\n\n /** @hidden first number is the CardDefinition rank, i.e. id */\n _singleItemColumns = new Set<number>();\n\n /** @hidden */\n _columnsWidth = new Map<number, number>();\n\n /** @hidden Return available width for fixed card layout */\n get _availableWidth(): number {\n return this._layout.nativeElement.getBoundingClientRect().width;\n }\n\n /** @hidden */\n _placeholderMargin: { [klass: string]: string };\n\n /** @hidden */\n private _previousNumberOfColumns: number;\n\n /** @hidden FocusKeyManager instance */\n private _keyboardEventsManager: FocusKeyManager<FixedCardLayoutItemComponent>;\n\n /** @hidden */\n private _cardMinimumWidth = CARD_MINIMUM_WIDTH;\n\n /** @hidden */\n private _shouldCalculateContainerHeight = false;\n\n /** @hidden An RxJS Subject that will kill the data stream upon component’s destruction (for unsubscribing) */\n private readonly _onDestroy$: Subject<void> = new Subject<void>();\n\n /** @hidden */\n constructor(\n private readonly _changeDetector: ChangeDetectorRef,\n @Optional() private readonly _rtlService: RtlService\n ) {}\n\n /** @hidden */\n ngOnInit(): void {\n this._subscribeToRtl();\n }\n\n /** @hidden */\n ngAfterContentInit(): void {\n this._listenOnCardsChange();\n }\n\n /** @hidden */\n ngAfterViewInit(): void {\n this._processCards();\n this._listenOnResize();\n this._accessibilitySetup();\n }\n\n /** @hidden */\n ngAfterViewChecked(): void {\n /**\n * Update column layout when orientation of screen changes.\n * actual width is returned when view is stable. In AfterViewInit, correct value does not come.\n */\n this.updateLayout();\n }\n\n /** @hidden */\n ngOnChanges(changes: SimpleChanges): void {\n if (!this._cards?.length) {\n return;\n }\n\n if ('maxColumns' in changes) {\n this.updateLayout();\n } else if ('columnsWidthConfig' in changes) {\n this._setColumnsWidth();\n }\n }\n\n /** @hidden */\n ngOnDestroy(): void {\n this._onDestroy$.next();\n this._onDestroy$.complete();\n }\n\n /** @hidden */\n @HostListener('keydown', ['$event'])\n handleKeydown(event: KeyboardEvent): void {\n event.stopImmediatePropagation();\n\n if (this._keyboardEventsManager) {\n this._keyboardEventsManager.onKeydown(event);\n }\n }\n\n /** Distribute cards on window resize */\n updateLayout(): void {\n if (!this._cards.length) {\n return;\n }\n\n const possibleNumberOfColumns = getNumberOfColumns(this._availableWidth, this.cardMinimumWidth);\n\n this._numberOfColumns = Math.min(\n possibleNumberOfColumns,\n this._cards.length,\n this.maxColumns || MAX_COLUMNS,\n MAX_COLUMNS\n );\n\n this.layoutChange.emit({\n numberOfColumns: this._numberOfColumns,\n screenSize: this._availableWidth\n });\n\n if (this._previousNumberOfColumns !== this._numberOfColumns) {\n this._previousNumberOfColumns = this._numberOfColumns;\n this._updateColumns();\n return;\n }\n\n this._setColumnsWidth();\n }\n\n /** @hidden Calculate container height basing on the card wrapper columns */\n _calculateContainerHeight(additionalSpace: number = 0): void {\n this._changeDetector.detectChanges();\n\n const wrapperColumns = this._cardColumns.map((column) =>\n column\n .map((card) => this._cardWrappers.find((wrapper) => wrapper.getSortedItems()[0].data === card)?.element)\n .filter((v): v is ElementRef<HTMLElement> => !!v)\n );\n\n const columnsHeights = wrapperColumns\n .map((column) => column.map((card) => card.nativeElement.getBoundingClientRect().height))\n .map((column) => column.reduce((height, cardHeight) => (height += cardHeight), 0));\n\n // +4px because it's the top & bottom borders of card placeholder\n this._containerHeight = Math.max(...columnsHeights) + 4 + additionalSpace;\n\n this._changeDetector.detectChanges();\n }\n\n /** @hidden */\n _enterPredicate = (_: CdkDrag, drop: CdkDropList): boolean => {\n // We should update container's height & its children rects (to react when drag moves into the list) before we entered any drop list.\n // That's why it's done here instead of cdkDropListEntered. As this predicate being called many times here is the optimization.\n if (this._shouldCalculateContainerHeight) {\n this._shouldCalculateContainerHeight = false;\n\n // Placeholder doesn't have margin set yet but we need to count it\n // Margin will be set only if there are already items in container\n const additionalSpace = drop.getSortedItems().length ? PX_IN_REM : 0;\n\n this._calculateContainerHeight(additionalSpace);\n }\n\n return true;\n };\n\n /** @hidden */\n _onDropListExited(): void {\n this._shouldCalculateContainerHeight = true;\n }\n\n /** @hidden */\n _onDropListEntered(event: CdkDragEnter): void {\n const containerItemCardDef = (event.container.getSortedItems()[0].data as CardDefinitionDirective).fdCardDef;\n const dragItemCardDef = (event.item.data as CardDefinitionDirective).fdCardDef;\n\n this._setPlaceholderStyle(containerItemCardDef !== dragItemCardDef);\n }\n\n /** @hidden */\n _onDragDropped(event: CdkDragDrop<number, number>): void {\n if (event.container.data === event.previousContainer.data) {\n return;\n }\n\n const movedCard = event.previousContainer.getSortedItems()[0].data;\n const replacedCard = event.container.getSortedItems()[0].data;\n\n const movedCardColumn = this._cardColumns.find((column) =>\n column.find((card) => card.fdCardDef === movedCard.fdCardDef)\n );\n const replacedCardColumn = this._cardColumns.find((column) =>\n column.find((card) => card.fdCardDef === replacedCard.fdCardDef)\n );\n\n // If we dragged the card from the same column as the column we're dropping into\n // There may be a situation where the order shouldn't change but since there are a different drop lists it will change\n // We should prevent this\n if (movedCardColumn === replacedCardColumn && movedCardColumn?.length === 2) {\n if (movedCard.fdCardDef < replacedCard.fdCardDef && event.previousContainer.data < event.container.data) {\n return;\n }\n\n if (movedCard.fdCardDef > replacedCard.fdCardDef && event.previousContainer.data > event.container.data) {\n return;\n }\n }\n\n this._processDragDrop(event.previousContainer.data, event.container.data, movedCard, replacedCard);\n }\n\n /** @hidden For the keyboard drag&drop directive */\n _customMoveFn = (group: CardColumn, indexFrom: number, indexTo: number): void => {\n const movedCard = group[indexFrom];\n const replacedCard = group[indexTo];\n\n const indexFromArray = this._cardsArray.findIndex((card) => card.fdCardDef === movedCard.fdCardDef);\n const indexToArray = this._cardsArray.findIndex((card) => card.fdCardDef === replacedCard.fdCardDef);\n\n this._processDragDrop(indexFromArray, indexToArray, movedCard, replacedCard);\n };\n\n /** @hidden For the keyboard drag&drop directive */\n _customTransferFn = (prevGroup: CardColumn, nextGroup: CardColumn, indexFrom: number, indexTo: number): void => {\n const movedCard = prevGroup[indexFrom];\n const replacedCard = nextGroup[indexTo];\n\n const indexFromArray = this._cardsArray.findIndex((card) => card.fdCardDef === movedCard.fdCardDef);\n const indexToArray = this._cardsArray.findIndex((card) => card.fdCardDef === replacedCard.fdCardDef);\n\n this._processDragDrop(indexFromArray, indexToArray, movedCard, replacedCard);\n };\n\n /** @hidden */\n _setPlaceholderStyle(value: boolean): void {\n this._placeholderMargin = value ? { 'margin-bottom': '1rem' } : {};\n }\n\n /** @hidden Arranges cards on drop of dragged card */\n private _processDragDrop(\n prevIndex: number,\n newIndex: number,\n prevCard: CardDefinitionDirective,\n newCard: CardDefinitionDirective\n ): void {\n // moveItemInArray from CDK won't work as it changes order of other cards\n const replacedCard = this._cardsArray[newIndex];\n this._cardsArray[newIndex] = this._cardsArray[prevIndex];\n this._cardsArray[prevIndex] = replacedCard;\n\n adjustCardRank(prevCard, newCard);\n\n this.cardDraggedDropped.emit({\n previousIndex: prevIndex,\n currentIndex: newIndex,\n layoutColumns: this._numberOfColumns,\n items: this._cards.toArray()\n });\n\n this._updateColumns();\n }\n\n /** @hidden */\n private _accessibilitySetup(): void {\n this._keyboardEventsManager = new FocusKeyManager(this._cardContainers).withWrap();\n }\n\n /** @hidden Rtl change subscription */\n private _subscribeToRtl(): void {\n this._rtlService?.rtl.pipe(takeUntil(this._onDestroy$)).subscribe((isRtl) => {\n this._dir = isRtl ? 'rtl' : 'ltr';\n this._changeDetector.detectChanges();\n });\n }\n\n /** @hidden Listen window resize and distribute cards on column change */\n private _listenOnResize(): void {\n resizeObservable(this._layout.nativeElement)\n .pipe(debounceTime(60), takeUntil(this._onDestroy$))\n .subscribe(() => this.updateLayout());\n }\n\n /** @hidden Listen card change and distribute cards on column change */\n private _listenOnCardsChange(): void {\n this._cards.changes.subscribe(() => {\n this._processCards();\n this._updateColumns();\n });\n }\n\n /** @hidden Renders layout on column changes */\n private _updateColumns(): void {\n this._setCardColumns();\n this._setColumnsWidth(false);\n this._calculateContainerHeight();\n }\n\n /** @hidden */\n private _processCards(): void {\n this._cardsArray = this._cards\n .toArray()\n .sort((firstCard, secondCard) => firstCard.fdCardDef - secondCard.fdCardDef);\n\n this._changeDetector.detectChanges();\n\n this.updateLayout();\n }\n\n /** @hidden Distribute cards among columns to arrange them in \"Z\" flow */\n private _setCardColumns(): void {\n this._groupIndexes = new Map<number, number>();\n this._itemIndexes = new Map<number, number>();\n this._singleItemColumns = new Set<number>();\n\n const columns: CardColumn[] = new Array(this._numberOfColumns).fill(0).map(() => new Array(0));\n\n this._cardsArray.forEach((card, i) => {\n const currColumnIndex = i % this._numberOfColumns;\n const itemIndex = columns[currColumnIndex].length;\n\n columns[currColumnIndex].push(card);\n\n this._groupIndexes.set(card.fdCardDef, currColumnIndex);\n this._itemIndexes.set(card.fdCardDef, itemIndex);\n });\n\n this._cardColumns = columns;\n\n this._cardColumns.forEach((column) => {\n if (column.length > 0 && column.length < 2) {\n this._singleItemColumns.add(column[0].fdCardDef);\n }\n });\n }\n\n /** @hidden */\n private _setColumnsWidth(detectChanges = true): void {\n this._columnsWidth = new Map();\n\n const configPresent =\n this.columnsWidthConfig &&\n typeof this.columnsWidthConfig === 'object' &&\n Object.keys(this.columnsWidthConfig).length;\n\n if (!configPresent || !this._layout || this._numberOfColumns === 1) {\n return;\n }\n\n const fixedWidthModifiers = fixWidthModifiers(this.columnsWidthConfig, this._numberOfColumns);\n const totalWidthModifiers = fixedWidthModifiers.reduce((sum, width) => (sum += width), 0);\n const freeSpace = this._availableWidth - this.cardMinimumWidth * this._numberOfColumns;\n\n this._cardColumns.forEach((column, index) => {\n const columnWidth = Math.round(\n this.cardMinimumWidth + (freeSpace / totalWidthModifiers) * fixedWidthModifiers[index]\n );\n\n column.forEach((card) => this._columnsWidth.set(card.fdCardDef, columnWidth));\n });\n\n if (detectChanges) {\n this._changeDetector.detectChanges();\n }\n }\n}\n\n/** @hidden */\nfunction fixWidthModifiers(config: ColumnsWidthConfig, numberOfColumns: number): number[] {\n const modifiers = new Array(numberOfColumns).fill(0);\n\n return modifiers.map((_, index) => {\n const columnWidthModifier = config[index + 1];\n\n if (!columnWidthModifier || columnWidthModifier < 0) {\n return 0;\n }\n\n return columnWidthModifier;\n });\n}\n\n/** @hidden Returns number of columns that can fit in current available width for fd-card-layout */\nfunction getNumberOfColumns(containerWidth: number, cardWidth: number): number {\n containerWidth = containerWidth || 1;\n cardWidth = cardWidth || 1;\n\n const numberOfCardsWithNoGap = Math.max(Math.floor(containerWidth / cardWidth), 1); // Example: 960 / 320 = 3\n const requiredWidthWithGap = numberOfCardsWithNoGap * cardWidth + (numberOfCardsWithNoGap - 1) * CARD_GAP_WIDTH;\n const columnCount = requiredWidthWithGap > containerWidth ? numberOfCardsWithNoGap - 1 : numberOfCardsWithNoGap;\n\n return Math.max(columnCount, 1);\n}\n\n/** @hidden Method to update rank after cards are dragged */\nfunction adjustCardRank(draggedCard: CardDefinitionDirective, replacedCard: CardDefinitionDirective): void {\n const draggedCardRank = draggedCard.fdCardDef;\n draggedCard.fdCardDef = replacedCard.fdCardDef;\n replacedCard.fdCardDef = draggedCardRank;\n}\n","<div\n #layout\n cdkDropListGroup\n fdDndKeyboardGroup\n class=\"fd-fixed-card-layout__card-layout fd-fixed-card-layout__card-layout--columns-{{ this._numberOfColumns }}\"\n [style.height]=\"_containerHeight + 'px'\"\n [groups]=\"_cardColumns\"\n orientation=\"horizontal\"\n [customMoveFn]=\"_customMoveFn\"\n [customTransferFn]=\"_customTransferFn\"\n [disableKeyboardDragDrop]=\"disableDragDrop\"\n [cdkDropListGroupDisabled]=\"disableDragDrop\"\n [attr.dir]=\"_dir\"\n>\n <div\n #dropList\n *ngFor=\"let card of _cardsArray; let cardIndex = index\"\n cdkDropList\n cdkDropListSortingDisabled\n class=\"fd-fixed-card-layout__card\"\n [class.fd-fixed-card-layout__card--single]=\"_singleItemColumns.has(card.fdCardDef)\"\n [style.min-width.px]=\"_columnsWidth.get(card.fdCardDef)\"\n [style.max-width.px]=\"_columnsWidth.get(card.fdCardDef)\"\n [cdkDropListData]=\"cardIndex\"\n [cdkDropListEnterPredicate]=\"_enterPredicate\"\n (cdkDropListEntered)=\"_onDropListEntered($event)\"\n (cdkDropListExited)=\"_onDropListExited()\"\n >\n <div\n cdkDrag\n fdDndKeyboardItem\n tabindex=\"0\"\n cdkDragPreviewClass=\"fd-fixed-card-layout__card-preview\"\n [cdkDragData]=\"card\"\n [cdkDragStartDelay]=\"dragStartDelay\"\n [itemIndex]=\"_itemIndexes.get(card.fdCardDef)!\"\n [groupIndex]=\"_groupIndexes.get(card.fdCardDef)!\"\n (cdkDragDropped)=\"_onDragDropped($event)\"\n (cdkDragStarted)=\"_setPlaceholderStyle(false)\"\n >\n <fd-fixed-card-layout-item>\n <ng-container *ngTemplateOutlet=\"card?.template || null\"> </ng-container>\n </fd-fixed-card-layout-item>\n\n <div *cdkDragPlaceholder class=\"fd-fixed-card-layout__card-placeholder\" [style]=\"_placeholderMargin\">\n <ng-container *ngTemplateOutlet=\"card?.template || null\"></ng-container>\n </div>\n </div>\n </div>\n\n <ng-container *ngFor=\"let column of _cardColumns; let last = last; let index = index\">\n <div *ngIf=\"!last\" class=\"fd-fixed-card-layout__clearfix\" [style.order]=\"index + 1\"></div>\n </ng-container>\n</div>\n","import { DragDropModule } from '@angular/cdk/drag-drop';\nimport { CommonModule } from '@angular/common';\nimport { NgModule } from '@angular/core';\nimport { FixedCardLayoutItemComponent } from './fixed-card-layout-item/fixed-card-layout-item.component';\nimport { DragAndDropModule } from '@fundamental-ngx/core/utils';\nimport { CardDefinitionDirective, FixedCardLayoutComponent } from './fixed-card-layout.component';\n\n@NgModule({\n declarations: [FixedCardLayoutComponent, CardDefinitionDirective, FixedCardLayoutItemComponent],\n imports: [CommonModule, DragDropModule, DragAndDropModule],\n exports: [FixedCardLayoutComponent, CardDefinitionDirective, FixedCardLayoutItemComponent]\n})\nexport class FixedCardLayoutModule {}\n","/**\n * Generated bundle index. Do not edit.\n */\n\nexport * from './public_api';\n"],"names":[],"mappings":";;;;;;;;;;;;;MAWa,4BAA4B;IACrC,YAAoB,WAAuB;QAAvB,gBAAW,GAAX,WAAW,CAAY;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,CAAC,CAAC,CAAC;AACpC,CAAC;AAED;AACA,SAAS,cAAc,CAAC,WAAoC,EAAE,YAAqC;IAC/F,MAAM,eAAe,GAAG,WAAW,CAAC,SAAS,CAAC;IAC9C,WAAW,CAAC,SAAS,GAAG,YAAY,CAAC,SAAS,CAAC;IAC/C,YAAY,CAAC,SAAS,GAAG,eAAe,CAAC;AAC7C;;ME3iBa,qBAAqB;;kHAArB,qBAAqB;mHAArB,qBAAqB,iBAJf,wBAAwB,EAAE,uBAAuB,EAAE,4BAA4B,aACpF,YAAY,EAAE,cAAc,EAAE,iBAAiB,aAC/C,wBAAwB,EAAE,uBAAuB,EAAE,4BAA4B;mHAEhF,qBAAqB,YAHrB,CAAC,YAAY,EAAE,cAAc,EAAE,iBAAiB,CAAC;2FAGjD,qBAAqB;kBALjC,QAAQ;mBAAC;oBACN,YAAY,EAAE,CAAC,wBAAwB,EAAE,uBAAuB,EAAE,4BAA4B,CAAC;oBAC/F,OAAO,EAAE,CAAC,YAAY,EAAE,cAAc,EAAE,iBAAiB,CAAC;oBAC1D,OAAO,EAAE,CAAC,wBAAwB,EAAE,uBAAuB,EAAE,4BAA4B,CAAC;iBAC7F;;;ACXD;;;;;;"}
1
+ {"version":3,"file":"fundamental-ngx-core-fixed-card-layout.mjs","sources":["../../../../libs/core/src/lib/fixed-card-layout/fixed-card-layout-item/fixed-card-layout-item.component.ts","../../../../libs/core/src/lib/fixed-card-layout/fixed-card-layout.component.ts","../../../../libs/core/src/lib/fixed-card-layout/fixed-card-layout.component.html","../../../../libs/core/src/lib/fixed-card-layout/fixed-card-layout.module.ts","../../../../libs/core/src/lib/fixed-card-layout/fundamental-ngx-core-fixed-card-layout.ts"],"sourcesContent":["import { ChangeDetectionStrategy, Component, ElementRef } from '@angular/core';\nimport { FocusableOption } from '@angular/cdk/a11y';\n\n@Component({\n selector: 'fd-fixed-card-layout-item',\n template: `<ng-content></ng-content>`,\n changeDetection: ChangeDetectionStrategy.OnPush,\n host: {\n style: 'display: block'\n }\n})\nexport class FixedCardLayoutItemComponent implements FocusableOption {\n constructor(private _elementRef: ElementRef) {}\n\n /** Set focus on the element. */\n focus(): void {\n const header = this._elementRef.nativeElement.querySelector('.fd-card__header');\n if (header) {\n header.focus();\n }\n }\n}\n","import {\n AfterContentInit,\n AfterViewInit,\n ChangeDetectionStrategy,\n ChangeDetectorRef,\n Component,\n ContentChildren,\n Directive,\n ElementRef,\n EventEmitter,\n HostListener,\n Input,\n OnChanges,\n OnDestroy,\n OnInit,\n Optional,\n Output,\n QueryList,\n SimpleChanges,\n TemplateRef,\n ViewChild,\n ViewChildren,\n ViewEncapsulation\n} from '@angular/core';\nimport { FocusKeyManager } from '@angular/cdk/a11y';\nimport { CdkDrag, CdkDragDrop, CdkDragEnter, CdkDropList } from '@angular/cdk/drag-drop';\nimport { Subject } from 'rxjs';\nimport { debounceTime, delay, takeUntil } from 'rxjs/operators';\n\nimport { resizeObservable, RtlService } from '@fundamental-ngx/core/utils';\nimport { FixedCardLayoutItemComponent } from './fixed-card-layout-item/fixed-card-layout-item.component';\nimport { coerceNumberProperty, NumberInput } from '@angular/cdk/coercion';\n\nconst PX_IN_REM = 16;\nconst CARD_MINIMUM_WIDTH = 320; // 320px = 20rem\nconst CARD_GAP_WIDTH = 16; // 16px = 1rem\nconst DRAG_START_DELAY = 200; // in ms\nconst MAX_COLUMNS = 10;\n\nlet cardRank = 1;\n\n@Directive({ selector: '[fdCardDef]' })\nexport class CardDefinitionDirective {\n /**\n * Behaves like rank of card.\n * Useful in creating layout again after drag and drop.\n */\n @Input()\n set fdCardDef(value: NumberInput) {\n if (!value) {\n return;\n }\n\n this._fdCardDef = coerceNumberProperty(value);\n }\n get fdCardDef(): number {\n return this._fdCardDef;\n }\n\n /** @hidden */\n private _fdCardDef: number = cardRank++;\n\n /** @hidden */\n constructor(public template: TemplateRef<any>) {}\n}\n\nexport interface Layout {\n numberOfColumns?: number;\n screenSize: number;\n}\n\nexport interface CardDropped {\n previousIndex: number;\n currentIndex: number;\n layoutColumns: number;\n items: CardDefinitionDirective[];\n}\n\ntype Columns = 1 | 2 | 3 | 4 | 5 | 6 | 7 | 8 | 9 | 10;\n\nexport type ColumnsWidthConfig = { [C in Columns]?: number };\n\ntype CardColumn = CardDefinitionDirective[];\n\n@Component({\n selector: 'fd-fixed-card-layout',\n templateUrl: './fixed-card-layout.component.html',\n styleUrls: ['./fixed-card-layout.component.scss'],\n changeDetection: ChangeDetectionStrategy.OnPush,\n encapsulation: ViewEncapsulation.None,\n host: {\n class: 'fd-fixed-card-layout'\n }\n})\nexport class FixedCardLayoutComponent implements OnInit, AfterContentInit, AfterViewInit, OnChanges, OnDestroy {\n /** Drag drop behavior can be disabled */\n @Input()\n disableDragDrop: boolean;\n\n /** Drag start delay in milliseconds, default to 200ms for safe scrolling on mobile with touchscreen */\n @Input()\n dragStartDelay = DRAG_START_DELAY;\n\n /** Card's minimum width in pixels. */\n @Input()\n set cardMinimumWidth(value: NumberInput) {\n const coercedValue = coerceNumberProperty(value);\n\n if (coercedValue < CARD_MINIMUM_WIDTH) {\n return;\n }\n\n this._cardMinimumWidth = coercedValue;\n\n // If component is ready, do the recalculation.\n if (this._layout) {\n this.updateLayout();\n }\n }\n get cardMinimumWidth(): number {\n return this._cardMinimumWidth;\n }\n\n /** Config with the width ratios that should take every column. Flex-grow principe. Missed values set to 0. s*/\n @Input()\n columnsWidthConfig: ColumnsWidthConfig;\n\n /** Limit the number of columns. Default is 10. */\n @Input()\n maxColumns = MAX_COLUMNS;\n\n /** Event to emit, when layout changes */\n @Output()\n layoutChange: EventEmitter<Layout> = new EventEmitter<Layout>();\n\n /** Event to emit on Card dragged and dropped */\n @Output()\n cardDraggedDropped: EventEmitter<CardDropped> = new EventEmitter<CardDropped>();\n\n /** @hidden */\n @ContentChildren(CardDefinitionDirective)\n _cards: QueryList<CardDefinitionDirective>;\n\n /** @hidden */\n @ViewChildren(FixedCardLayoutItemComponent)\n _cardContainers: QueryList<FixedCardLayoutItemComponent>;\n\n /** @hidden */\n @ViewChildren('dropList', { read: CdkDropList })\n _cardWrappers: QueryList<CdkDropList>;\n\n /** @hidden */\n @ViewChild('layout')\n _layout: ElementRef;\n\n /** @hidden */\n _cardsArray: Array<CardDefinitionDirective>;\n\n /** @hidden Number of Columns in layout */\n _numberOfColumns: number;\n\n /** @hidden */\n _cardColumns: CardColumn[];\n\n /** @hidden*/\n _containerHeight: number;\n\n /** @hidden handles rtl service */\n _dir = 'ltr';\n\n /** @hidden first number is the CardDefinition rank, i.e. id */\n _groupIndexes = new Map<number, number>();\n\n /** @hidden first number is the CardDefinition rank, i.e. id */\n _itemIndexes = new Map<number, number>();\n\n /** @hidden first number is the CardDefinition rank, i.e. id */\n _singleItemColumns = new Set<number>();\n\n /** @hidden */\n _columnsWidth = new Map<number, number>();\n\n /** @hidden Return available width for fixed card layout */\n get _availableWidth(): number {\n return this._layout.nativeElement.getBoundingClientRect().width;\n }\n\n /** @hidden */\n _placeholderMargin: { [klass: string]: string };\n\n /** @hidden */\n private _previousNumberOfColumns: number;\n\n /** @hidden FocusKeyManager instance */\n private _keyboardEventsManager: FocusKeyManager<FixedCardLayoutItemComponent>;\n\n /** @hidden */\n private _cardMinimumWidth = CARD_MINIMUM_WIDTH;\n\n /** @hidden */\n private _shouldCalculateContainerHeight = false;\n\n /** @hidden An RxJS Subject that will kill the data stream upon component’s destruction (for unsubscribing) */\n private readonly _onDestroy$: Subject<void> = new Subject<void>();\n\n /** @hidden */\n constructor(\n private readonly _changeDetector: ChangeDetectorRef,\n @Optional() private readonly _rtlService: RtlService\n ) {}\n\n /** @hidden */\n ngOnInit(): void {\n this._subscribeToRtl();\n }\n\n /** @hidden */\n ngAfterContentInit(): void {\n this._listenOnCardsChange();\n }\n\n /** @hidden */\n ngAfterViewInit(): void {\n this._processCards();\n this._listenOnResize();\n this._accessibilitySetup();\n }\n\n /** @hidden */\n ngOnChanges(changes: SimpleChanges): void {\n if (!this._cards?.length) {\n return;\n }\n\n if ('maxColumns' in changes) {\n this.updateLayout();\n } else if ('columnsWidthConfig' in changes) {\n this._setColumnsWidth();\n }\n }\n\n /** @hidden */\n ngOnDestroy(): void {\n this._onDestroy$.next();\n this._onDestroy$.complete();\n }\n\n /** @hidden */\n @HostListener('keydown', ['$event'])\n handleKeydown(event: KeyboardEvent): void {\n event.stopImmediatePropagation();\n\n if (this._keyboardEventsManager) {\n this._keyboardEventsManager.onKeydown(event);\n }\n }\n\n /** Distribute cards on window resize */\n updateLayout(): void {\n if (!this._cards.length || !this._availableWidth) {\n return;\n }\n\n const possibleNumberOfColumns = getNumberOfColumns(this._availableWidth, this.cardMinimumWidth);\n\n this._numberOfColumns = Math.min(\n possibleNumberOfColumns,\n this._cards.length,\n this.maxColumns || MAX_COLUMNS,\n MAX_COLUMNS\n );\n\n this.layoutChange.emit({\n numberOfColumns: this._numberOfColumns,\n screenSize: this._availableWidth\n });\n\n if (this._previousNumberOfColumns !== this._numberOfColumns) {\n this._previousNumberOfColumns = this._numberOfColumns;\n this._updateColumns();\n return;\n }\n\n this._setColumnsWidth();\n }\n\n /** @hidden */\n _enterPredicate = (_: CdkDrag, drop: CdkDropList): boolean => {\n // We should update container's height & its children rects (to react when drag moves into the list) before we entered any drop list.\n // That's why it's done here instead of cdkDropListEntered. As this predicate being called many times here is the optimization.\n if (this._shouldCalculateContainerHeight) {\n this._shouldCalculateContainerHeight = false;\n\n // Placeholder doesn't have margin set yet but we need to count it\n // Margin will be set only if there are already items in container\n const additionalSpace = drop.getSortedItems().length ? PX_IN_REM : 0;\n\n this._calculateContainerHeight(additionalSpace);\n }\n\n return true;\n };\n\n /** @hidden */\n _onDropListExited(): void {\n this._shouldCalculateContainerHeight = true;\n }\n\n /** @hidden */\n _onDropListEntered(event: CdkDragEnter): void {\n const containerItemCardDef = (event.container.getSortedItems()[0].data as CardDefinitionDirective).fdCardDef;\n const dragItemCardDef = (event.item.data as CardDefinitionDirective).fdCardDef;\n\n this._setPlaceholderStyle(containerItemCardDef !== dragItemCardDef);\n }\n\n /** @hidden */\n _onDragDropped(event: CdkDragDrop<number, number>): void {\n if (event.container.data === event.previousContainer.data) {\n return;\n }\n\n const movedCard = event.previousContainer.getSortedItems()[0].data;\n const replacedCard = event.container.getSortedItems()[0].data;\n\n const movedCardColumn = this._cardColumns.find((column) =>\n column.find((card) => card.fdCardDef === movedCard.fdCardDef)\n );\n const replacedCardColumn = this._cardColumns.find((column) =>\n column.find((card) => card.fdCardDef === replacedCard.fdCardDef)\n );\n\n // If we dragged the card from the same column as the column we're dropping into\n // There may be a situation where the order shouldn't change but since there are a different drop lists it will change\n // We should prevent this\n if (movedCardColumn === replacedCardColumn && movedCardColumn?.length === 2) {\n if (movedCard.fdCardDef < replacedCard.fdCardDef && event.previousContainer.data < event.container.data) {\n return;\n }\n\n if (movedCard.fdCardDef > replacedCard.fdCardDef && event.previousContainer.data > event.container.data) {\n return;\n }\n }\n\n this._processDragDrop(event.previousContainer.data, event.container.data, movedCard, replacedCard);\n }\n\n /** @hidden For the keyboard drag&drop directive */\n _customMoveFn = (group: CardColumn, indexFrom: number, indexTo: number): void => {\n const movedCard = group[indexFrom];\n const replacedCard = group[indexTo];\n\n const indexFromArray = this._cardsArray.findIndex((card) => card.fdCardDef === movedCard.fdCardDef);\n const indexToArray = this._cardsArray.findIndex((card) => card.fdCardDef === replacedCard.fdCardDef);\n\n this._processDragDrop(indexFromArray, indexToArray, movedCard, replacedCard);\n };\n\n /** @hidden For the keyboard drag&drop directive */\n _customTransferFn = (prevGroup: CardColumn, nextGroup: CardColumn, indexFrom: number, indexTo: number): void => {\n const movedCard = prevGroup[indexFrom];\n const replacedCard = nextGroup[indexTo];\n\n const indexFromArray = this._cardsArray.findIndex((card) => card.fdCardDef === movedCard.fdCardDef);\n const indexToArray = this._cardsArray.findIndex((card) => card.fdCardDef === replacedCard.fdCardDef);\n\n this._processDragDrop(indexFromArray, indexToArray, movedCard, replacedCard);\n };\n\n /** @hidden */\n _setPlaceholderStyle(value: boolean): void {\n this._placeholderMargin = value ? { 'margin-bottom': '1rem' } : {};\n }\n\n /** @hidden Arranges cards on drop of dragged card */\n private _processDragDrop(\n prevIndex: number,\n newIndex: number,\n prevCard: CardDefinitionDirective,\n newCard: CardDefinitionDirective\n ): void {\n // moveItemInArray from CDK won't work as it changes order of other cards\n const replacedCard = this._cardsArray[newIndex];\n this._cardsArray[newIndex] = this._cardsArray[prevIndex];\n this._cardsArray[prevIndex] = replacedCard;\n\n adjustCardRank(prevCard, newCard);\n\n this.cardDraggedDropped.emit({\n previousIndex: prevIndex,\n currentIndex: newIndex,\n layoutColumns: this._numberOfColumns,\n items: this._cards.toArray()\n });\n\n this._updateColumns();\n }\n\n /** @hidden */\n private _accessibilitySetup(): void {\n this._keyboardEventsManager = new FocusKeyManager(this._cardContainers).withWrap();\n }\n\n /** @hidden Rtl change subscription */\n private _subscribeToRtl(): void {\n this._rtlService?.rtl.pipe(takeUntil(this._onDestroy$)).subscribe((isRtl) => {\n this._dir = isRtl ? 'rtl' : 'ltr';\n this._changeDetector.detectChanges();\n });\n }\n\n /** @hidden Listen window resize and distribute cards on column change */\n private _listenOnResize(): void {\n resizeObservable(this._layout.nativeElement)\n .pipe(debounceTime(60), takeUntil(this._onDestroy$))\n .subscribe(() => this.updateLayout());\n }\n\n /** @hidden Listen card change and distribute cards on column change */\n private _listenOnCardsChange(): void {\n this._cards.changes.pipe(delay(0)).subscribe(() => {\n this._processCards();\n this._updateColumns();\n });\n }\n\n /** @hidden Renders layout on column changes */\n private _updateColumns(): void {\n this._setCardColumns();\n this._setColumnsWidth(false);\n this._calculateContainerHeight();\n }\n\n /** @hidden */\n private _processCards(): void {\n this._cardsArray = this._cards\n .toArray()\n .sort((firstCard, secondCard) => firstCard.fdCardDef - secondCard.fdCardDef);\n\n this.updateLayout();\n }\n\n /** @hidden Distribute cards among columns to arrange them in \"Z\" flow */\n private _setCardColumns(): void {\n this._groupIndexes = new Map<number, number>();\n this._itemIndexes = new Map<number, number>();\n this._singleItemColumns = new Set<number>();\n\n const columns: CardColumn[] = new Array(this._numberOfColumns).fill(0).map(() => new Array(0));\n\n this._cardsArray.forEach((card, i) => {\n const currColumnIndex = i % this._numberOfColumns;\n const itemIndex = columns[currColumnIndex].length;\n\n columns[currColumnIndex].push(card);\n\n this._groupIndexes.set(card.fdCardDef, currColumnIndex);\n this._itemIndexes.set(card.fdCardDef, itemIndex);\n });\n\n this._cardColumns = columns;\n\n this._cardColumns.forEach((column) => {\n if (column.length > 0 && column.length < 2) {\n this._singleItemColumns.add(column[0].fdCardDef);\n }\n });\n }\n\n /** @hidden */\n private _setColumnsWidth(detectChanges = true): void {\n this._columnsWidth = new Map();\n\n const configPresent =\n this.columnsWidthConfig &&\n typeof this.columnsWidthConfig === 'object' &&\n Object.keys(this.columnsWidthConfig).length;\n\n if (!configPresent || !this._layout || this._numberOfColumns === 1) {\n return;\n }\n\n const fixedWidthModifiers = fixWidthModifiers(this.columnsWidthConfig, this._numberOfColumns);\n const totalWidthModifiers = fixedWidthModifiers.reduce((sum, width) => (sum += width), 0);\n const freeSpace = this._availableWidth - this.cardMinimumWidth * this._numberOfColumns;\n\n this._cardColumns.forEach((column, index) => {\n const columnWidth = Math.round(\n this.cardMinimumWidth + (freeSpace / totalWidthModifiers) * fixedWidthModifiers[index]\n );\n\n column.forEach((card) => this._columnsWidth.set(card.fdCardDef, columnWidth));\n });\n\n if (detectChanges) {\n this._changeDetector.detectChanges();\n }\n }\n\n /** @hidden Calculate container height basing on the card wrapper columns */\n private _calculateContainerHeight(additionalSpace: number = 0): void {\n this._changeDetector.detectChanges();\n\n const wrapperColumns = this._cardColumns.map((column) =>\n column\n .map((card) => this._cardWrappers.find((wrapper) => wrapper.getSortedItems()[0].data === card)?.element)\n .filter((v): v is ElementRef<HTMLElement> => !!v)\n );\n\n const columnsHeights = wrapperColumns\n .map((column) => column.map((card) => card.nativeElement.getBoundingClientRect().height))\n .map((column) => column.reduce((height, cardHeight) => (height += cardHeight), 0));\n\n // +4px because it's the top & bottom borders of card placeholder\n this._containerHeight = Math.max(...columnsHeights) + 4 + additionalSpace;\n\n this._changeDetector.detectChanges();\n }\n}\n\n/** @hidden */\nfunction fixWidthModifiers(config: ColumnsWidthConfig, numberOfColumns: number): number[] {\n const modifiers = new Array(numberOfColumns).fill(0);\n\n return modifiers.map((_, index) => {\n const columnWidthModifier = config[index + 1];\n\n if (!columnWidthModifier || columnWidthModifier < 0) {\n return 0;\n }\n\n return columnWidthModifier;\n });\n}\n\n/** @hidden Returns number of columns that can fit in current available width for fd-card-layout */\nfunction getNumberOfColumns(containerWidth: number, cardWidth: number): number {\n containerWidth = containerWidth || 1;\n cardWidth = cardWidth || 1;\n\n const numberOfCardsWithNoGap = Math.max(Math.floor(containerWidth / cardWidth), 1); // Example: 960 / 320 = 3\n const requiredWidthWithGap = numberOfCardsWithNoGap * cardWidth + (numberOfCardsWithNoGap - 1) * CARD_GAP_WIDTH;\n const columnCount = requiredWidthWithGap > containerWidth ? numberOfCardsWithNoGap - 1 : numberOfCardsWithNoGap;\n\n return Math.max(columnCount, 1);\n}\n\n/** @hidden Method to update rank after cards are dragged */\nfunction adjustCardRank(draggedCard: CardDefinitionDirective, replacedCard: CardDefinitionDirective): void {\n const draggedCardRank = draggedCard.fdCardDef;\n draggedCard.fdCardDef = replacedCard.fdCardDef;\n replacedCard.fdCardDef = draggedCardRank;\n}\n","<div\n #layout\n cdkDropListGroup\n fdDndKeyboardGroup\n class=\"fd-fixed-card-layout__card-layout fd-fixed-card-layout__card-layout--columns-{{ this._numberOfColumns }}\"\n [style.height]=\"_containerHeight + 'px'\"\n [groups]=\"_cardColumns\"\n orientation=\"horizontal\"\n [customMoveFn]=\"_customMoveFn\"\n [customTransferFn]=\"_customTransferFn\"\n [disableKeyboardDragDrop]=\"disableDragDrop\"\n [cdkDropListGroupDisabled]=\"disableDragDrop\"\n [attr.dir]=\"_dir\"\n>\n <div\n #dropList\n *ngFor=\"let card of _cardsArray; let cardIndex = index\"\n cdkDropList\n cdkDropListSortingDisabled\n class=\"fd-fixed-card-layout__card\"\n [class.fd-fixed-card-layout__card--single]=\"_singleItemColumns.has(card.fdCardDef)\"\n [style.min-width.px]=\"_columnsWidth.get(card.fdCardDef)\"\n [style.max-width.px]=\"_columnsWidth.get(card.fdCardDef)\"\n [cdkDropListData]=\"cardIndex\"\n [cdkDropListEnterPredicate]=\"_enterPredicate\"\n (cdkDropListEntered)=\"_onDropListEntered($event)\"\n (cdkDropListExited)=\"_onDropListExited()\"\n >\n <div\n cdkDrag\n fdDndKeyboardItem\n tabindex=\"0\"\n cdkDragPreviewClass=\"fd-fixed-card-layout__card-preview\"\n [cdkDragData]=\"card\"\n [cdkDragStartDelay]=\"dragStartDelay\"\n [itemIndex]=\"_itemIndexes.get(card.fdCardDef)!\"\n [groupIndex]=\"_groupIndexes.get(card.fdCardDef)!\"\n (cdkDragDropped)=\"_onDragDropped($event)\"\n (cdkDragStarted)=\"_setPlaceholderStyle(false)\"\n >\n <fd-fixed-card-layout-item>\n <ng-container *ngTemplateOutlet=\"card?.template || null\"> </ng-container>\n </fd-fixed-card-layout-item>\n\n <div *cdkDragPlaceholder class=\"fd-fixed-card-layout__card-placeholder\" [style]=\"_placeholderMargin\">\n <ng-container *ngTemplateOutlet=\"card?.template || null\"></ng-container>\n </div>\n </div>\n </div>\n\n <ng-container *ngFor=\"let column of _cardColumns; let last = last; let index = index\">\n <div *ngIf=\"!last\" class=\"fd-fixed-card-layout__clearfix\" [style.order]=\"index + 1\"></div>\n </ng-container>\n</div>\n","import { DragDropModule } from '@angular/cdk/drag-drop';\nimport { CommonModule } from '@angular/common';\nimport { NgModule } from '@angular/core';\nimport { FixedCardLayoutItemComponent } from './fixed-card-layout-item/fixed-card-layout-item.component';\nimport { DragAndDropModule } from '@fundamental-ngx/core/utils';\nimport { CardDefinitionDirective, FixedCardLayoutComponent } from './fixed-card-layout.component';\n\n@NgModule({\n declarations: [FixedCardLayoutComponent, CardDefinitionDirective, FixedCardLayoutItemComponent],\n imports: [CommonModule, DragDropModule, DragAndDropModule],\n exports: [FixedCardLayoutComponent, CardDefinitionDirective, FixedCardLayoutItemComponent]\n})\nexport class FixedCardLayoutModule {}\n","/**\n * Generated bundle index. Do not edit.\n */\n\nexport * from './public_api';\n"],"names":[],"mappings":";;;;;;;;;;;;;MAWa,4BAA4B;IACrC,YAAoB,WAAuB;QAAvB,gBAAW,GAAX,WAAW,CAAY;KAAI;;IAG/C,KAAK;QACD,MAAM,MAAM,GAAG,IAAI,CAAC,WAAW,CAAC,aAAa,CAAC,aAAa,CAAC,kBAAkB,CAAC,CAAC;QAChF,IAAI,MAAM,EAAE;YACR,MAAM,CAAC,KAAK,EAAE,CAAC;SAClB;KACJ;;yHATQ,4BAA4B;6GAA5B,4BAA4B,6GAN3B,2BAA2B;2FAM5B,4BAA4B;kBARxC,SAAS;mBAAC;oBACP,QAAQ,EAAE,2BAA2B;oBACrC,QAAQ,EAAE,2BAA2B;oBACrC,eAAe,EAAE,uBAAuB,CAAC,MAAM;oBAC/C,IAAI,EAAE;wBACF,KAAK,EAAE,gBAAgB;qBAC1B;iBACJ;;;ACuBD,MAAM,SAAS,GAAG,EAAE,CAAC;AACrB,MAAM,kBAAkB,GAAG,GAAG,CAAC;AAC/B,MAAM,cAAc,GAAG,EAAE,CAAC;AAC1B,MAAM,gBAAgB,GAAG,GAAG,CAAC;AAC7B,MAAM,WAAW,GAAG,EAAE,CAAC;AAEvB,IAAI,QAAQ,GAAG,CAAC,CAAC;MAGJ,uBAAuB;;IAqBhC,YAAmB,QAA0B;QAA1B,aAAQ,GAAR,QAAQ,CAAkB;;QAHrC,eAAU,GAAW,QAAQ,EAAE,CAAC;KAGS;;;;;IAhBjD,IACI,SAAS,CAAC,KAAkB;QAC5B,IAAI,CAAC,KAAK,EAAE;YACR,OAAO;SACV;QAED,IAAI,CAAC,UAAU,GAAG,oBAAoB,CAAC,KAAK,CAAC,CAAC;KACjD;IACD,IAAI,SAAS;QACT,OAAO,IAAI,CAAC,UAAU,CAAC;KAC1B;;o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