@openui5/sap.m 1.105.1 → 1.107.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (471) hide show
  1. package/.reuse/dep5 +20 -17
  2. package/THIRDPARTY.txt +31 -21
  3. package/package.json +4 -4
  4. package/src/sap/m/.library +20 -1
  5. package/src/sap/m/AccButton.js +4 -3
  6. package/src/sap/m/ActionListItem.js +14 -11
  7. package/src/sap/m/ActionSelect.js +14 -11
  8. package/src/sap/m/ActionSheet.js +103 -101
  9. package/src/sap/m/ActionSheetRenderer.js +3 -3
  10. package/src/sap/m/ActionTile.js +90 -0
  11. package/src/sap/m/ActionTileContent.js +71 -0
  12. package/src/sap/m/ActionTileContentRenderer.js +108 -0
  13. package/src/sap/m/App.js +107 -104
  14. package/src/sap/m/AssociativeOverflowToolbar.js +1 -1
  15. package/src/sap/m/Avatar.js +4 -3
  16. package/src/sap/m/AvatarColor.js +0 -1
  17. package/src/sap/m/AvatarImageFitType.js +0 -1
  18. package/src/sap/m/AvatarShape.js +0 -1
  19. package/src/sap/m/AvatarSize.js +0 -1
  20. package/src/sap/m/AvatarType.js +0 -1
  21. package/src/sap/m/Bar.js +103 -89
  22. package/src/sap/m/BarRenderer.js +3 -3
  23. package/src/sap/m/Breadcrumbs.js +4 -3
  24. package/src/sap/m/BusyDialog.js +1 -2
  25. package/src/sap/m/BusyIndicator.js +76 -73
  26. package/src/sap/m/Button.js +123 -120
  27. package/src/sap/m/Carousel.js +148 -147
  28. package/src/sap/m/CarouselLayout.js +1 -2
  29. package/src/sap/m/CarouselRenderer.js +3 -3
  30. package/src/sap/m/CheckBox.js +178 -175
  31. package/src/sap/m/CheckBoxRenderer.js +3 -3
  32. package/src/sap/m/ColorPalette.js +4 -3
  33. package/src/sap/m/ColorPalettePopover.js +24 -21
  34. package/src/sap/m/Column.js +5 -6
  35. package/src/sap/m/ColumnHeaderPopover.js +1 -2
  36. package/src/sap/m/ColumnListItem.js +39 -50
  37. package/src/sap/m/ColumnListItemRenderer.js +0 -3
  38. package/src/sap/m/ColumnPopoverActionItem.js +1 -2
  39. package/src/sap/m/ColumnPopoverCustomItem.js +1 -2
  40. package/src/sap/m/ColumnPopoverItem.js +1 -2
  41. package/src/sap/m/ColumnPopoverSelectListItem.js +1 -1
  42. package/src/sap/m/ColumnPopoverSortItem.js +1 -2
  43. package/src/sap/m/ComboBox.js +4 -3
  44. package/src/sap/m/ComboBoxBase.js +3 -4
  45. package/src/sap/m/ComboBoxTextField.js +4 -3
  46. package/src/sap/m/CustomAttribute.js +53 -0
  47. package/src/sap/m/CustomDynamicDateOption.js +1 -2
  48. package/src/sap/m/CustomListItem.js +24 -21
  49. package/src/sap/m/CustomTile.js +19 -16
  50. package/src/sap/m/CustomTreeItem.js +4 -3
  51. package/src/sap/m/DatePicker.js +148 -143
  52. package/src/sap/m/DateRangeSelection.js +45 -40
  53. package/src/sap/m/DateTimeField.js +11 -8
  54. package/src/sap/m/DateTimeInput.js +147 -142
  55. package/src/sap/m/DateTimePicker.js +83 -75
  56. package/src/sap/m/DateTimePickerRenderer.js +1 -1
  57. package/src/sap/m/Dialog.js +10 -7
  58. package/src/sap/m/DisplayListItem.js +23 -20
  59. package/src/sap/m/DraftIndicator.js +4 -3
  60. package/src/sap/m/DynamicDate.js +1 -1
  61. package/src/sap/m/DynamicDateFormat.js +4 -3
  62. package/src/sap/m/DynamicDateOption.js +1 -2
  63. package/src/sap/m/DynamicDateRange.js +11 -10
  64. package/src/sap/m/DynamicDateValueHelpUIType.js +1 -2
  65. package/src/sap/m/ExpandableText.js +4 -3
  66. package/src/sap/m/FacetFilter.js +112 -110
  67. package/src/sap/m/FacetFilterItem.js +27 -24
  68. package/src/sap/m/FacetFilterList.js +131 -132
  69. package/src/sap/m/FeedContent.js +4 -3
  70. package/src/sap/m/FeedInput.js +136 -133
  71. package/src/sap/m/FeedListItem.js +9 -6
  72. package/src/sap/m/FeedListItemAction.js +1 -2
  73. package/src/sap/m/FeedListItemRenderer.js +3 -3
  74. package/src/sap/m/Fiori20Adapter.js +2 -2
  75. package/src/sap/m/FlexBox.js +96 -93
  76. package/src/sap/m/FlexItemData.js +1 -2
  77. package/src/sap/m/FormattedText.js +4 -3
  78. package/src/sap/m/GenericTag.js +5 -4
  79. package/src/sap/m/GenericTile.js +65 -22
  80. package/src/sap/m/GenericTileLineModeRenderer.js +3 -3
  81. package/src/sap/m/GenericTileRenderer.js +36 -10
  82. package/src/sap/m/GroupHeaderListItem.js +35 -32
  83. package/src/sap/m/GrowingEnablement.js +23 -25
  84. package/src/sap/m/GrowingList.js +35 -32
  85. package/src/sap/m/HBox.js +9 -6
  86. package/src/sap/m/HeaderContainer.js +44 -43
  87. package/src/sap/m/HeaderContainerItemNavigator.js +1 -1
  88. package/src/sap/m/IconTabBar.js +232 -229
  89. package/src/sap/m/IconTabBarDragAndDropUtil.js +5 -4
  90. package/src/sap/m/IconTabBarSelectList.js +28 -25
  91. package/src/sap/m/IconTabFilter.js +1 -2
  92. package/src/sap/m/IconTabFilterExpandButtonBadge.js +1 -2
  93. package/src/sap/m/IconTabHeader.js +152 -166
  94. package/src/sap/m/IconTabSeparator.js +1 -2
  95. package/src/sap/m/IllustratedMessage.js +38 -3
  96. package/src/sap/m/IllustratedMessageSize.js +0 -1
  97. package/src/sap/m/IllustratedMessageType.js +0 -1
  98. package/src/sap/m/Illustration.js +11 -3
  99. package/src/sap/m/IllustrationPool.js +1 -1
  100. package/src/sap/m/IllustrationRenderer.js +1 -0
  101. package/src/sap/m/Image.js +270 -197
  102. package/src/sap/m/ImageContent.js +4 -3
  103. package/src/sap/m/ImageRenderer.js +66 -2
  104. package/src/sap/m/Input.js +375 -367
  105. package/src/sap/m/InputBase.js +143 -140
  106. package/src/sap/m/InputBaseRenderer.js +3 -3
  107. package/src/sap/m/InputListItem.js +26 -23
  108. package/src/sap/m/InputRenderer.js +4 -4
  109. package/src/sap/m/InstanceManager.js +6 -6
  110. package/src/sap/m/Label.js +110 -106
  111. package/src/sap/m/LightBox.js +5 -6
  112. package/src/sap/m/LightBoxItem.js +1 -2
  113. package/src/sap/m/Link.js +182 -179
  114. package/src/sap/m/LinkRenderer.js +5 -1
  115. package/src/sap/m/List.js +15 -12
  116. package/src/sap/m/ListBase.js +452 -458
  117. package/src/sap/m/ListItemBase.js +116 -107
  118. package/src/sap/m/ListItemBaseRenderer.js +1 -1
  119. package/src/sap/m/MaskEnabler.js +5 -5
  120. package/src/sap/m/MaskInput.js +4 -3
  121. package/src/sap/m/MaskInputRule.js +1 -2
  122. package/src/sap/m/Menu.js +1 -2
  123. package/src/sap/m/MenuButton.js +142 -135
  124. package/src/sap/m/MenuItem.js +1 -2
  125. package/src/sap/m/MenuListItem.js +49 -46
  126. package/src/sap/m/MessageItem.js +1 -2
  127. package/src/sap/m/MessageListItem.js +4 -3
  128. package/src/sap/m/MessagePage.js +124 -121
  129. package/src/sap/m/MessagePopover.js +6 -6
  130. package/src/sap/m/MessagePopoverItem.js +1 -2
  131. package/src/sap/m/MessageStrip.js +4 -3
  132. package/src/sap/m/MessageToast.js +6 -5
  133. package/src/sap/m/MessageView.js +6 -5
  134. package/src/sap/m/MultiComboBox.js +84 -87
  135. package/src/sap/m/MultiEditField.js +1 -1
  136. package/src/sap/m/MultiInput.js +4 -3
  137. package/src/sap/m/NavContainer.js +6 -15
  138. package/src/sap/m/NewsContent.js +4 -3
  139. package/src/sap/m/NotificationList.js +4 -3
  140. package/src/sap/m/NotificationListBase.js +5 -7
  141. package/src/sap/m/NotificationListGroup.js +4 -3
  142. package/src/sap/m/NotificationListItem.js +4 -12
  143. package/src/sap/m/NumericContent.js +8 -6
  144. package/src/sap/m/NumericInput.js +1 -1
  145. package/src/sap/m/NumericInputRenderer.js +3 -3
  146. package/src/sap/m/ObjectAttribute.js +77 -74
  147. package/src/sap/m/ObjectAttributeRenderer.js +3 -3
  148. package/src/sap/m/ObjectHeader.js +385 -380
  149. package/src/sap/m/ObjectHeaderRenderer.js +4 -3
  150. package/src/sap/m/ObjectIdentifier.js +111 -103
  151. package/src/sap/m/ObjectListItem.js +150 -145
  152. package/src/sap/m/ObjectMarker.js +4 -3
  153. package/src/sap/m/ObjectNumber.js +90 -87
  154. package/src/sap/m/ObjectStatus.js +84 -81
  155. package/src/sap/m/OverflowToolbar.js +4 -3
  156. package/src/sap/m/OverflowToolbarAssociativePopover.js +1 -1
  157. package/src/sap/m/OverflowToolbarAssociativePopoverControls.js +0 -5
  158. package/src/sap/m/OverflowToolbarButton.js +2 -3
  159. package/src/sap/m/OverflowToolbarLayoutData.js +1 -2
  160. package/src/sap/m/OverflowToolbarToggleButton.js +1 -2
  161. package/src/sap/m/P13nAnyFilterItem.js +1 -2
  162. package/src/sap/m/P13nColumnsItem.js +1 -2
  163. package/src/sap/m/P13nColumnsPanel.js +4 -5
  164. package/src/sap/m/P13nConditionPanel.js +1 -2
  165. package/src/sap/m/P13nDialog.js +1 -2
  166. package/src/sap/m/P13nDimMeasureItem.js +1 -2
  167. package/src/sap/m/P13nDimMeasurePanel.js +6 -5
  168. package/src/sap/m/P13nFilterItem.js +1 -2
  169. package/src/sap/m/P13nFilterPanel.js +1 -2
  170. package/src/sap/m/P13nGroupItem.js +1 -2
  171. package/src/sap/m/P13nGroupPanel.js +1 -2
  172. package/src/sap/m/P13nItem.js +1 -2
  173. package/src/sap/m/P13nPanel.js +1 -2
  174. package/src/sap/m/P13nSelectionItem.js +1 -2
  175. package/src/sap/m/P13nSelectionPanel.js +1 -2
  176. package/src/sap/m/P13nSortItem.js +1 -2
  177. package/src/sap/m/P13nSortPanel.js +1 -2
  178. package/src/sap/m/PDFViewer.js +8 -5
  179. package/src/sap/m/Page.js +9 -7
  180. package/src/sap/m/PageAccessibleLandmarkInfo.js +1 -2
  181. package/src/sap/m/PagingButton.js +4 -4
  182. package/src/sap/m/Panel.js +117 -113
  183. package/src/sap/m/PlanningCalendar.js +6 -7
  184. package/src/sap/m/PlanningCalendarHeader.js +135 -129
  185. package/src/sap/m/PlanningCalendarLegend.js +26 -23
  186. package/src/sap/m/PlanningCalendarRow.js +1 -2
  187. package/src/sap/m/PlanningCalendarView.js +1 -2
  188. package/src/sap/m/Popover.js +15 -16
  189. package/src/sap/m/PopoverRenderer.js +5 -4
  190. package/src/sap/m/ProgressIndicator.js +85 -82
  191. package/src/sap/m/ProgressIndicatorRenderer.js +1 -1
  192. package/src/sap/m/PullToRefresh.js +37 -35
  193. package/src/sap/m/QuickView.js +1 -2
  194. package/src/sap/m/QuickViewBase.js +1 -2
  195. package/src/sap/m/QuickViewCard.js +4 -3
  196. package/src/sap/m/QuickViewGroup.js +1 -2
  197. package/src/sap/m/QuickViewGroupElement.js +1 -2
  198. package/src/sap/m/QuickViewPage.js +1 -2
  199. package/src/sap/m/RadioButton.js +117 -114
  200. package/src/sap/m/RadioButtonGroup.js +90 -95
  201. package/src/sap/m/RangeSlider.js +9 -6
  202. package/src/sap/m/RangeSliderRenderer.js +2 -2
  203. package/src/sap/m/RatingIndicator.js +104 -100
  204. package/src/sap/m/RatingIndicatorRenderer.js +3 -5
  205. package/src/sap/m/ResponsivePopover.js +209 -209
  206. package/src/sap/m/ResponsiveScale.js +1 -2
  207. package/src/sap/m/ScrollBar.js +31 -28
  208. package/src/sap/m/ScrollContainer.js +9 -7
  209. package/src/sap/m/SearchField.js +185 -182
  210. package/src/sap/m/SearchFieldRenderer.js +1 -0
  211. package/src/sap/m/SegmentedButton.js +120 -118
  212. package/src/sap/m/SegmentedButtonItem.js +1 -2
  213. package/src/sap/m/Select.js +23 -10
  214. package/src/sap/m/SelectDialog.js +22 -17
  215. package/src/sap/m/SelectDialogBase.js +1 -2
  216. package/src/sap/m/SelectList.js +4 -3
  217. package/src/sap/m/SelectionDetails.js +97 -92
  218. package/src/sap/m/SelectionDetailsFacade.js +2 -2
  219. package/src/sap/m/SelectionDetailsItem.js +1 -2
  220. package/src/sap/m/SelectionDetailsItemLine.js +1 -2
  221. package/src/sap/m/Shell.js +111 -107
  222. package/src/sap/m/SimpleFixFlex.js +5 -5
  223. package/src/sap/m/SinglePlanningCalendar.js +344 -340
  224. package/src/sap/m/SinglePlanningCalendarDayView.js +1 -1
  225. package/src/sap/m/SinglePlanningCalendarGrid.js +25 -10
  226. package/src/sap/m/SinglePlanningCalendarGridRenderer.js +8 -7
  227. package/src/sap/m/SinglePlanningCalendarMonthGrid.js +16 -7
  228. package/src/sap/m/SinglePlanningCalendarMonthView.js +1 -1
  229. package/src/sap/m/SinglePlanningCalendarView.js +1 -1
  230. package/src/sap/m/SinglePlanningCalendarWeekView.js +15 -15
  231. package/src/sap/m/SinglePlanningCalendarWorkWeekView.js +5 -4
  232. package/src/sap/m/SlideTile.js +10 -7
  233. package/src/sap/m/Slider.js +180 -175
  234. package/src/sap/m/SliderRenderer.js +4 -4
  235. package/src/sap/m/SliderTooltip.js +5 -5
  236. package/src/sap/m/SliderTooltipBase.js +4 -3
  237. package/src/sap/m/SliderTooltipContainer.js +10 -6
  238. package/src/sap/m/SplitApp.js +52 -49
  239. package/src/sap/m/SplitButton.js +103 -96
  240. package/src/sap/m/SplitContainer.js +407 -422
  241. package/src/sap/m/StandardDynamicDateOption.js +1 -2
  242. package/src/sap/m/StandardListItem.js +116 -113
  243. package/src/sap/m/StandardTile.js +64 -61
  244. package/src/sap/m/StandardTreeItem.js +20 -17
  245. package/src/sap/m/StepInput.js +4 -3
  246. package/src/sap/m/SuggestionItem.js +1 -2
  247. package/src/sap/m/SuggestionsPopover.js +1 -1
  248. package/src/sap/m/Switch.js +79 -74
  249. package/src/sap/m/SwitchRenderer.js +3 -3
  250. package/src/sap/m/TabContainer.js +4 -3
  251. package/src/sap/m/TabContainerItem.js +1 -2
  252. package/src/sap/m/TabStrip.js +13 -11
  253. package/src/sap/m/TabStripItem.js +1 -1
  254. package/src/sap/m/Table.js +177 -174
  255. package/src/sap/m/TablePersoController.js +6 -5
  256. package/src/sap/m/TablePersoDialog.js +6 -4
  257. package/src/sap/m/TablePersoProvider.js +1 -1
  258. package/src/sap/m/TableRenderer.js +1 -1
  259. package/src/sap/m/TableSelectDialog.js +1 -3
  260. package/src/sap/m/Text.js +4 -3
  261. package/src/sap/m/TextArea.js +87 -84
  262. package/src/sap/m/Tile.js +20 -17
  263. package/src/sap/m/TileContainer.js +73 -73
  264. package/src/sap/m/TileContent.js +57 -6
  265. package/src/sap/m/TimePicker.js +17 -12
  266. package/src/sap/m/TimePickerClock.js +2 -2
  267. package/src/sap/m/TimePickerClocks.js +4 -2
  268. package/src/sap/m/TimePickerClocksRenderer.js +3 -1
  269. package/src/sap/m/TimePickerInputs.js +4 -2
  270. package/src/sap/m/TimePickerInternals.js +11 -7
  271. package/src/sap/m/TimePickerSlider.js +5 -4
  272. package/src/sap/m/TimePickerSliders.js +11 -7
  273. package/src/sap/m/TimePickerSlidersRenderer.js +2 -2
  274. package/src/sap/m/Title.js +109 -106
  275. package/src/sap/m/TitlePropagationSupport.js +4 -4
  276. package/src/sap/m/ToDoCardRenderer.js +161 -0
  277. package/src/sap/m/ToggleButton.js +29 -26
  278. package/src/sap/m/Token.js +97 -94
  279. package/src/sap/m/Tokenizer.js +153 -150
  280. package/src/sap/m/Toolbar.js +104 -101
  281. package/src/sap/m/ToolbarLayoutData.js +1 -2
  282. package/src/sap/m/ToolbarSeparator.js +11 -8
  283. package/src/sap/m/ToolbarSpacer.js +16 -13
  284. package/src/sap/m/Tree.js +32 -29
  285. package/src/sap/m/TreeItemBase.js +8 -5
  286. package/src/sap/m/TreeItemBaseRenderer.js +3 -3
  287. package/src/sap/m/UploadCollection.js +8 -5
  288. package/src/sap/m/UploadCollectionItem.js +1 -2
  289. package/src/sap/m/UploadCollectionParameter.js +1 -2
  290. package/src/sap/m/UploadCollectionToolbarPlaceholder.js +1 -2
  291. package/src/sap/m/VBox.js +9 -6
  292. package/src/sap/m/ValueStateHeader.js +1 -2
  293. package/src/sap/m/VariantItem.js +6 -1
  294. package/src/sap/m/VariantManagement.js +79 -8
  295. package/src/sap/m/ViewSettingsCustomItem.js +1 -2
  296. package/src/sap/m/ViewSettingsCustomTab.js +1 -2
  297. package/src/sap/m/ViewSettingsDialog.js +189 -188
  298. package/src/sap/m/ViewSettingsFilterItem.js +1 -2
  299. package/src/sap/m/ViewSettingsItem.js +1 -2
  300. package/src/sap/m/VisibleItem.js +1 -1
  301. package/src/sap/m/WheelSlider.js +5 -4
  302. package/src/sap/m/WheelSliderContainer.js +4 -2
  303. package/src/sap/m/WheelSliderContainerRenderer.js +2 -2
  304. package/src/sap/m/Wizard.js +13 -3
  305. package/src/sap/m/WizardProgressNavigator.js +52 -49
  306. package/src/sap/m/WizardStep.js +6 -3
  307. package/src/sap/m/_thirdparty/purify.js +1622 -0
  308. package/src/sap/m/changeHandler/AddTableColumn.js +1 -1
  309. package/src/sap/m/changeHandler/ChangeLinkTarget.js +1 -1
  310. package/src/sap/m/changeHandler/CombineButtons.js +4 -3
  311. package/src/sap/m/changeHandler/MoveTableColumns.js +1 -1
  312. package/src/sap/m/changeHandler/SelectIconTabBarFilter.js +1 -1
  313. package/src/sap/m/changeHandler/SplitMenuButton.js +1 -1
  314. package/src/sap/m/library.js +40 -116
  315. package/src/sap/m/messagebundle.properties +22 -10
  316. package/src/sap/m/messagebundle_ar.properties +20 -6
  317. package/src/sap/m/messagebundle_bg.properties +19 -5
  318. package/src/sap/m/messagebundle_ca.properties +19 -5
  319. package/src/sap/m/messagebundle_cs.properties +30 -16
  320. package/src/sap/m/messagebundle_cy.properties +19 -5
  321. package/src/sap/m/messagebundle_da.properties +19 -5
  322. package/src/sap/m/messagebundle_de.properties +20 -6
  323. package/src/sap/m/messagebundle_el.properties +19 -5
  324. package/src/sap/m/messagebundle_en.properties +18 -4
  325. package/src/sap/m/messagebundle_en_GB.properties +18 -4
  326. package/src/sap/m/messagebundle_en_US_sappsd.properties +19 -3
  327. package/src/sap/m/messagebundle_en_US_saprigi.properties +23 -9
  328. package/src/sap/m/messagebundle_en_US_saptrc.properties +16 -2
  329. package/src/sap/m/messagebundle_es.properties +19 -5
  330. package/src/sap/m/messagebundle_es_MX.properties +19 -5
  331. package/src/sap/m/messagebundle_et.properties +19 -5
  332. package/src/sap/m/messagebundle_fi.properties +19 -5
  333. package/src/sap/m/messagebundle_fr.properties +20 -6
  334. package/src/sap/m/messagebundle_fr_CA.properties +20 -6
  335. package/src/sap/m/messagebundle_hi.properties +19 -5
  336. package/src/sap/m/messagebundle_hr.properties +20 -6
  337. package/src/sap/m/messagebundle_hu.properties +19 -5
  338. package/src/sap/m/messagebundle_id.properties +19 -5
  339. package/src/sap/m/messagebundle_it.properties +20 -6
  340. package/src/sap/m/messagebundle_iw.properties +19 -5
  341. package/src/sap/m/messagebundle_ja.properties +19 -5
  342. package/src/sap/m/messagebundle_kk.properties +19 -5
  343. package/src/sap/m/messagebundle_ko.properties +20 -6
  344. package/src/sap/m/messagebundle_lt.properties +20 -6
  345. package/src/sap/m/messagebundle_lv.properties +19 -5
  346. package/src/sap/m/messagebundle_ms.properties +19 -5
  347. package/src/sap/m/messagebundle_nl.properties +19 -5
  348. package/src/sap/m/messagebundle_no.properties +19 -5
  349. package/src/sap/m/messagebundle_pl.properties +19 -5
  350. package/src/sap/m/messagebundle_pt.properties +19 -5
  351. package/src/sap/m/messagebundle_pt_PT.properties +19 -5
  352. package/src/sap/m/messagebundle_ro.properties +19 -5
  353. package/src/sap/m/messagebundle_ru.properties +19 -5
  354. package/src/sap/m/messagebundle_sh.properties +20 -6
  355. package/src/sap/m/messagebundle_sk.properties +19 -5
  356. package/src/sap/m/messagebundle_sl.properties +20 -6
  357. package/src/sap/m/messagebundle_sv.properties +19 -5
  358. package/src/sap/m/messagebundle_th.properties +19 -5
  359. package/src/sap/m/messagebundle_tr.properties +19 -5
  360. package/src/sap/m/messagebundle_uk.properties +19 -5
  361. package/src/sap/m/messagebundle_vi.properties +19 -5
  362. package/src/sap/m/messagebundle_zh_CN.properties +19 -5
  363. package/src/sap/m/messagebundle_zh_TW.properties +19 -5
  364. package/src/sap/m/p13n/AbstractContainer.js +2 -2
  365. package/src/sap/m/p13n/AbstractContainerItem.js +2 -2
  366. package/src/sap/m/p13n/BasePanel.js +21 -7
  367. package/src/sap/m/p13n/Container.js +1 -1
  368. package/src/sap/m/p13n/Engine.js +84 -79
  369. package/src/sap/m/p13n/GroupController.js +3 -4
  370. package/src/sap/m/p13n/GroupPanel.js +1 -1
  371. package/src/sap/m/p13n/MetadataHelper.js +8 -0
  372. package/src/sap/m/p13n/Popup.js +1 -1
  373. package/src/sap/m/p13n/QueryPanel.js +1 -1
  374. package/src/sap/m/p13n/SelectionController.js +8 -7
  375. package/src/sap/m/p13n/SelectionPanel.js +37 -15
  376. package/src/sap/m/p13n/SortController.js +3 -4
  377. package/src/sap/m/p13n/SortPanel.js +3 -3
  378. package/src/sap/m/p13n/modification/FlexModificationHandler.js +1 -1
  379. package/src/sap/m/p13n/modification/LocalStorageModificationHandler.js +1 -1
  380. package/src/sap/m/p13n/modification/ModificationHandler.js +11 -0
  381. package/src/sap/m/p13n/modules/DefaultProviderRegistry.js +1 -1
  382. package/src/sap/m/p13n/modules/StateHandlerRegistry.js +1 -1
  383. package/src/sap/m/p13n/modules/UIManager.js +1 -1
  384. package/src/sap/m/plugins/CellSelector.js +459 -76
  385. package/src/sap/m/plugins/ColumnResizer.js +1 -2
  386. package/src/sap/m/plugins/DataStateIndicator.js +1 -2
  387. package/src/sap/m/plugins/PasteProvider.js +1 -2
  388. package/src/sap/m/plugins/PluginBase.js +1 -2
  389. package/src/sap/m/rules/CheckBox.support.js +1 -1
  390. package/src/sap/m/rules/Image.support.js +1 -1
  391. package/src/sap/m/rules/Link.support.js +1 -1
  392. package/src/sap/m/rules/MessagePage.support.js +1 -1
  393. package/src/sap/m/rules/ObjectHeader.support.js +6 -6
  394. package/src/sap/m/rules/ObjectListItem.support.js +1 -1
  395. package/src/sap/m/rules/ObjectMarker.support.js +1 -1
  396. package/src/sap/m/rules/ObjectStatus.support.js +1 -1
  397. package/src/sap/m/rules/Panel.support.js +1 -1
  398. package/src/sap/m/rules/Select.support.js +1 -1
  399. package/src/sap/m/rules/Table.support.js +3 -3
  400. package/src/sap/m/semantic/AddAction.js +1 -2
  401. package/src/sap/m/semantic/CancelAction.js +1 -2
  402. package/src/sap/m/semantic/DeleteAction.js +1 -2
  403. package/src/sap/m/semantic/DetailPage.js +1 -2
  404. package/src/sap/m/semantic/DiscussInJamAction.js +1 -2
  405. package/src/sap/m/semantic/EditAction.js +1 -2
  406. package/src/sap/m/semantic/FavoriteAction.js +1 -2
  407. package/src/sap/m/semantic/FilterAction.js +1 -2
  408. package/src/sap/m/semantic/FilterSelect.js +1 -2
  409. package/src/sap/m/semantic/FlagAction.js +1 -2
  410. package/src/sap/m/semantic/ForwardAction.js +1 -2
  411. package/src/sap/m/semantic/FullscreenPage.js +1 -2
  412. package/src/sap/m/semantic/GroupAction.js +1 -2
  413. package/src/sap/m/semantic/GroupSelect.js +1 -2
  414. package/src/sap/m/semantic/MainAction.js +1 -2
  415. package/src/sap/m/semantic/MasterPage.js +1 -2
  416. package/src/sap/m/semantic/MessagesIndicator.js +1 -2
  417. package/src/sap/m/semantic/MultiSelectAction.js +1 -2
  418. package/src/sap/m/semantic/NegativeAction.js +1 -2
  419. package/src/sap/m/semantic/OpenInAction.js +1 -2
  420. package/src/sap/m/semantic/PositiveAction.js +1 -2
  421. package/src/sap/m/semantic/PrintAction.js +1 -2
  422. package/src/sap/m/semantic/SaveAction.js +1 -2
  423. package/src/sap/m/semantic/Segment.js +1 -2
  424. package/src/sap/m/semantic/SegmentedContainer.js +1 -1
  425. package/src/sap/m/semantic/SemanticButton.js +1 -2
  426. package/src/sap/m/semantic/SemanticConfiguration.js +1 -2
  427. package/src/sap/m/semantic/SemanticControl.js +1 -2
  428. package/src/sap/m/semantic/SemanticOverflowToolbarButton.js +1 -2
  429. package/src/sap/m/semantic/SemanticOverflowToolbarToggleButton.js +1 -2
  430. package/src/sap/m/semantic/SemanticPage.js +4 -3
  431. package/src/sap/m/semantic/SemanticSelect.js +1 -2
  432. package/src/sap/m/semantic/SemanticToggleButton.js +1 -2
  433. package/src/sap/m/semantic/SendEmailAction.js +1 -2
  434. package/src/sap/m/semantic/SendMessageAction.js +1 -2
  435. package/src/sap/m/semantic/ShareInJamAction.js +1 -2
  436. package/src/sap/m/semantic/ShareMenu.js +1 -2
  437. package/src/sap/m/semantic/ShareMenuPage.js +1 -2
  438. package/src/sap/m/semantic/SortAction.js +1 -2
  439. package/src/sap/m/semantic/SortSelect.js +1 -2
  440. package/src/sap/m/table/Util.js +17 -5
  441. package/src/sap/m/table/columnmenu/ActionItem.js +1 -1
  442. package/src/sap/m/table/columnmenu/Entry.js +1 -1
  443. package/src/sap/m/table/columnmenu/Item.js +1 -1
  444. package/src/sap/m/table/columnmenu/ItemBase.js +2 -2
  445. package/src/sap/m/table/columnmenu/ItemContainer.js +1 -1
  446. package/src/sap/m/table/columnmenu/Menu.js +64 -22
  447. package/src/sap/m/table/columnmenu/QuickAction.js +16 -8
  448. package/src/sap/m/table/columnmenu/QuickActionBase.js +19 -4
  449. package/src/sap/m/table/columnmenu/QuickActionContainer.js +1 -1
  450. package/src/sap/m/table/columnmenu/QuickActionItem.js +5 -6
  451. package/src/sap/m/table/columnmenu/QuickGroup.js +9 -3
  452. package/src/sap/m/table/columnmenu/QuickGroupItem.js +1 -1
  453. package/src/sap/m/table/columnmenu/QuickSort.js +6 -4
  454. package/src/sap/m/table/columnmenu/QuickSortItem.js +11 -12
  455. package/src/sap/m/table/columnmenu/QuickTotal.js +9 -3
  456. package/src/sap/m/table/columnmenu/QuickTotalItem.js +1 -1
  457. package/src/sap/m/themes/base/ActionTile.less +239 -0
  458. package/src/sap/m/themes/base/Bar.less +6 -0
  459. package/src/sap/m/themes/base/Carousel.less +8 -8
  460. package/src/sap/m/themes/base/CellSelector.less +109 -2
  461. package/src/sap/m/themes/base/DisplayListItem.less +3 -3
  462. package/src/sap/m/themes/base/GenericTile.less +7 -0
  463. package/src/sap/m/themes/base/IconTabBar.less +2 -0
  464. package/src/sap/m/themes/base/Link.less +4 -0
  465. package/src/sap/m/themes/base/Page.less +2 -1
  466. package/src/sap/m/themes/base/library.source.less +1 -0
  467. package/src/sap/m/upload/UploadSet.js +295 -13
  468. package/src/sap/m/upload/UploadSetItem.js +1 -2
  469. package/src/sap/m/upload/UploadSetToolbarPlaceholder.js +1 -1
  470. package/src/sap/m/upload/Uploader.js +0 -1
  471. package/src/sap/m/upload/UploaderHttpRequestMethod.js +0 -1
@@ -17,6 +17,14 @@ sap.ui.define([
17
17
  PREVIOUS: 2
18
18
  };
19
19
 
20
+ var MOUSE_POSITION = {
21
+ ABOVE: 0,
22
+ RIGHT: 1,
23
+ BELOW: 2,
24
+ LEFT: 3,
25
+ IN: 4
26
+ };
27
+
20
28
  var CSS_CLASS = "sapMPluginsCellSelector";
21
29
 
22
30
  /**
@@ -37,9 +45,15 @@ sap.ui.define([
37
45
  * - SHIFT + END: Enhances the current cell selection block to the end of the covered rows.
38
46
  * - CTRL + SHIFT + A: Clears the selection.
39
47
  *
48
+ * Mouse Usage:
49
+ * - Left Click: Select the clicked cell.
50
+ * - Mousedown + Moving: Select an area of cells.
51
+ * - Drag Borders: Drag the horizontal/vertical borders to enhance the cell selection in the corresponding direction.
52
+ * - Drag Edge: Enhance your current cell selection in any direction, when dragging a corner.
53
+ *
40
54
  * @extends sap.m.plugins.PluginBase
41
55
  * @class
42
- * @version 1.105.1
56
+ * @version 1.107.0
43
57
  * @author SAP SE
44
58
  *
45
59
  * @private
@@ -57,18 +71,46 @@ sap.ui.define([
57
71
  oControl.addDelegate(this, true, this);
58
72
  this._oSession = {};
59
73
  this._oSession.oCanvas = {};
74
+ this._oSession.oEdge = {};
75
+ this._oSession.oBorderLine = {};
60
76
 
61
77
  var sScrollEvent = this.getConfig("scrollEvent");
62
78
  sScrollEvent && oControl.attachEvent(sScrollEvent, this._handleScroll, this);
79
+
80
+ this._fnMouseupHandler = this._onmouseup.bind(this);
81
+ document.addEventListener("mouseup", this._fnMouseupHandler);
82
+ var oContainerRef = this.getControl().getDomRef(this.getConfig("scrollContainer"));
83
+ if (oContainerRef) {
84
+ this._fnMouseleaveHandler = this._onMouseLeave.bind(this);
85
+ oContainerRef.addEventListener("mouseleave", this._fnMouseleaveHandler);
86
+ }
63
87
  };
64
88
 
65
89
  CellSelector.prototype.onDeactivate = function (oControl) {
66
90
  oControl.removeDelegate(this, this);
67
91
  this._oSession = {};
68
92
  this._oSession.oCanvas = {};
93
+ this._oSession.oEdge = {};
94
+ this._oSession.oBorderLine = {};
69
95
 
70
96
  var sScrollEvent = this.getConfig("scrollEvent");
71
97
  sScrollEvent && oControl.detachEvent(sScrollEvent, this._handleScroll, this);
98
+
99
+ document.removeEventListener("mouseup", this._fnMouseupHandler);
100
+ var oContainerRef = this.getControl().getDomRef(this.getConfig("scrollContainer"));
101
+ if (oContainerRef) {
102
+ oContainerRef.removeEventListener("mouseleave", this._fnMouseleaveHandler);
103
+ }
104
+ };
105
+
106
+ CellSelector.prototype.onAfterRendering = function () {
107
+ this._fnMouseupHandler = this._onmouseup.bind(this);
108
+ document.addEventListener("mouseup", this._fnMouseupHandler);
109
+ var oContainerRef = this.getControl().getDomRef(this.getConfig("scrollContainer"));
110
+ if (oContainerRef) {
111
+ this._fnMouseleaveHandler = this._onMouseLeave.bind(this);
112
+ oContainerRef.addEventListener("mouseleave", this._fnMouseleaveHandler);
113
+ }
72
114
  };
73
115
 
74
116
  /**
@@ -134,7 +176,7 @@ sap.ui.define([
134
176
  if (!this._bSelecting) {
135
177
  return;
136
178
  }
137
- this._clearSelection();
179
+ this.clearSelection();
138
180
  };
139
181
 
140
182
  CellSelector.prototype.onsaphome = CellSelector.prototype.onsapend = CellSelector.prototype.onsapnext;
@@ -221,7 +263,7 @@ sap.ui.define([
221
263
  if (this._bSelecting) {
222
264
  // CTRL+SHIFT+A: Clear Selection
223
265
  if (isKeyCombination(oEvent, KeyCodes.A, true, true)) {
224
- this._clearSelection();
266
+ this.clearSelection();
225
267
  }
226
268
  oEvent.preventDefault();
227
269
  oEvent.setMarked();
@@ -235,6 +277,205 @@ sap.ui.define([
235
277
  oEvent.setMarked();
236
278
  };
237
279
 
280
+ // Mouse Navigation
281
+
282
+ CellSelector.prototype.ontouchstart = function (oEvent) {
283
+ var oCellRef = this._getSelectableCell(oEvent.target);
284
+ if (oEvent.isMarked() || !oCellRef) {
285
+ return;
286
+ } else if (!this.getConfig("isSelectionEnabled", this.getControl())) {
287
+ Log.error("Cell selection is inactive, because preconditions are not met.");
288
+ return;
289
+ }
290
+
291
+ var oCellInfo = this.getConfig("getCellInfo", this.getControl(), oCellRef);
292
+
293
+ if (oCellInfo) {
294
+ this._bSelecting = true;
295
+ this._bMouseDown = true;
296
+ this._bByEdge = false;
297
+ if (this._oSession.mSource) {
298
+ if (this._oSession.mSource.rowIndex !== oCellInfo.rowIndex || this._oSession.mSource.colIndex !== oCellInfo.colIndex) {
299
+ this._oSession.mSource = null;
300
+ this._oSession.mTarget = null;
301
+ }
302
+ }
303
+
304
+ this._oSession.mSource = oCellInfo;
305
+ this._oSession.mStart = oCellInfo;
306
+ this._selectCells(this._oSession.mSource, oCellInfo, {info: {focus: oCellInfo}});
307
+ oEvent.preventDefault();
308
+ }
309
+ oEvent.setMarked();
310
+ };
311
+
312
+ CellSelector.prototype.ontouchmove = function (oEvent) {
313
+ if (!this._bMouseDown || !this._bSelecting) {
314
+ return;
315
+ }
316
+
317
+ var oTouchPosition = this._getMousePosition(this.getConfig("scrollContainer"), oEvent.clientX, oEvent.clientY);
318
+ if (oTouchPosition.x == MOUSE_POSITION.IN && oTouchPosition.y == MOUSE_POSITION.IN) {
319
+ this._bScrollSelecting = false;
320
+ }
321
+
322
+ var oTargetRef = this._getSelectableCell(oEvent.target);
323
+ if (!oTargetRef) {
324
+ return;
325
+ }
326
+
327
+ var oTargetInfo = this.getConfig("getCellInfo", this.getControl(), oTargetRef);
328
+ if (oTargetInfo) {
329
+ if (oTargetInfo.rowIndex == this._oSession.mTarget.rowIndex && oTargetInfo.colIndex == this._oSession.mTarget.colIndex) {
330
+ // if current mouse position is equal to current saved target position, no change is needed
331
+ return;
332
+ }
333
+
334
+ var oBounds = getNormalizedBounds(this._oSession.mSource, this._oSession.mTarget);
335
+
336
+ if (this._oEdgeInfo && this._oEdgeInfo.isActive && this._oEdgeInfo.moveStart) {
337
+ this._oEdgeInfo.moveStart = false;
338
+
339
+ // Move Start position to opposite edge to ensure correct enlarging/decreasing of selection area
340
+ if (this._oEdgeInfo.edgePosition === "NE") {
341
+ this._oSession.mStart.rowIndex = oBounds.to.rowIndex;
342
+ this._oSession.mStart.colIndex = oBounds.from.colIndex;
343
+ } else if (this._oEdgeInfo.edgePosition === "SE") {
344
+ this._oSession.mStart = oBounds.from;
345
+ } else if (this._oEdgeInfo.edgePosition === "SW") {
346
+ this._oSession.mStart.rowIndex = oBounds.from.rowIndex;
347
+ this._oSession.mStart.colIndex = oBounds.to.colIndex;
348
+ } else if (this._oEdgeInfo.edgePosition === "NW") {
349
+ this._oSession.mStart = oBounds.to;
350
+ }
351
+ } else if (this._oBorderMoveInfo && this._oBorderMoveInfo.isActive) {
352
+ // Move Start position to opposite border to ensure correct enlarging/decreasing of selection area
353
+ var sDirection = this._oBorderMoveInfo.direction, bMoveStart = this._oBorderMoveInfo.moveStart;
354
+ if (sDirection === "N") {
355
+ this._oSession.mStart = bMoveStart ? oBounds.to : this._oSession.mStart;
356
+ oTargetInfo.colIndex = oBounds.from.colIndex;
357
+ } else if (sDirection === "E") {
358
+ this._oSession.mStart = bMoveStart ? oBounds.from : this._oSession.mStart;
359
+ oTargetInfo.rowIndex = oBounds.to.rowIndex;
360
+ } else if (sDirection === "S") {
361
+ this._oSession.mStart = bMoveStart ? oBounds.from : this._oSession.mStart;
362
+ oTargetInfo.colIndex = oBounds.to.colIndex;
363
+ } else if (sDirection === "W") {
364
+ this._oSession.mStart = bMoveStart ? oBounds.to : this._oSession.mStart;
365
+ oTargetInfo.rowIndex = oBounds.from.rowIndex;
366
+ }
367
+ this._oBorderMoveInfo.moveStart = false;
368
+ }
369
+ var mFrom = this._oSession.mStart, mTo = oTargetInfo;
370
+ this._selectCells(mFrom, mTo, {info: {focus: oTargetInfo}});
371
+ }
372
+ };
373
+
374
+ CellSelector.prototype._onMouseLeave = function (oEvent) {
375
+ if (this._bMouseDown && this._bSelecting) {
376
+ this._bScrollSelecting = true;
377
+ var oMousePosition = this._getMousePosition(this.getConfig("scrollContainer"), oEvent.clientX, oEvent.clientY);
378
+ this._onScrollSelect(oMousePosition);
379
+ }
380
+ };
381
+
382
+ /**
383
+ * Event handler for scroll selection. If the mouse is outside of the table while selecting cells, the table will be scrolled accordingly.
384
+ *
385
+ * Returns a promise, which will resolve if selection is stopped or the control has been destroyed.
386
+ * @param {object} oMousePosition mouse position information
387
+ * @param {MOUSE_POSITION} oMousePosition.x x position
388
+ * @param {MOUSE_POSITION} oMousePosition.y y position
389
+ * @returns {Promise} event promise
390
+ */
391
+ CellSelector.prototype._onScrollSelect = function (oMousePosition) {
392
+ // recursively calls _onScrollSelect every 100ms, as long as scroll selecting is active
393
+ return new Promise(function (resolve, reject) {
394
+ if (!this._bScrollSelecting) {
395
+ resolve();
396
+ return;
397
+ }
398
+ setTimeout(function () {
399
+ if (!this.getControl()) {
400
+ // If during the asynchronous process, the control is somehow destroyed, simply resolve and return
401
+ resolve();
402
+ return;
403
+ }
404
+ var oContainerRef = this.getControl().getDomRef(this.getConfig("container"));
405
+ if (oMousePosition.x === MOUSE_POSITION.LEFT) {
406
+ if (this._oSession.mSource.colIndex < this._oSession.mTarget.colIndex && this._oSession.mSource.colIndex > 0) {
407
+ this._oSession.mSource.colIndex--;
408
+ } else if (this._oSession.mTarget.colIndex > 0) {
409
+ this._oSession.mTarget.colIndex--;
410
+ }
411
+ oContainerRef.dispatchEvent(new WheelEvent("wheel", {deltaX: -1, deltaMode: window.WheelEvent.DOM_DELTA_LINE}));
412
+ this._selectCells(this._oSession.mSource, this._oSession.mTarget);
413
+ } else if (oMousePosition.x === MOUSE_POSITION.RIGHT) {
414
+ this._oSession.mTarget.colIndex++;
415
+ oContainerRef.dispatchEvent(new WheelEvent("wheel", {deltaX: 1, deltaMode: window.WheelEvent.DOM_DELTA_LINE}));
416
+ this._selectCells(this._oSession.mSource, this._oSession.mTarget);
417
+ }
418
+ if (oMousePosition.y === MOUSE_POSITION.ABOVE) {
419
+ if (this._oSession.mSource.rowIndex < this._oSession.mTarget.rowIndex && this._oSession.mSource.rowIndex > 0) {
420
+ this._oSession.mSource.rowIndex--;
421
+ } else if (this._oSession.mTarget.rowIndex > 0) {
422
+ this._oSession.mTarget.rowIndex--;
423
+ }
424
+ oContainerRef.dispatchEvent(new WheelEvent("wheel", {deltaY: -1, deltaMode: window.WheelEvent.DOM_DELTA_LINE}));
425
+ } else if (oMousePosition.y === MOUSE_POSITION.BELOW) {
426
+ this._oSession.mTarget.rowIndex++;
427
+ oContainerRef.dispatchEvent(new WheelEvent("wheel", {deltaY: 1, deltaMode: window.WheelEvent.DOM_DELTA_LINE}));
428
+ }
429
+ resolve();
430
+ }.bind(this), 100);
431
+ }.bind(this)).then(function () {
432
+ if (!this._bScrollSelecting) {
433
+ return;
434
+ }
435
+ this._onScrollSelect(oMousePosition);
436
+ }.bind(this));
437
+ };
438
+
439
+ /**
440
+ * Event handler for mouse movement with border or edge handles while selecting cells. Sets the according selection flags, if a selection is active.
441
+ * @param {String} sFacing direction of movement
442
+ * @param {boolean} bBorder is the movement by border dragging
443
+ * @private
444
+ */
445
+ CellSelector.prototype._onHandleMove = function (sFacing, bBorder) {
446
+ if (this._oBorderMoveInfo && this._oBorderMoveInfo.isActive) {
447
+ return;
448
+ }
449
+ this._bSelecting = true;
450
+ this._bMouseDown = true;
451
+ if (bBorder) {
452
+ this._oBorderMoveInfo = {isActive: true, direction: sFacing, moveStart: true};
453
+ } else {
454
+ this._oEdgeInfo = {isActive: true, moveStart: true, edgePosition: sFacing};
455
+ }
456
+ };
457
+
458
+ /**
459
+ * Event handler for mouseup. Stops the cell selection and sets the necessary flags accordingly.
460
+ * @param {sap.ui.base.Event} oEvent event object
461
+ * @private
462
+ */
463
+ CellSelector.prototype._onmouseup = function (oEvent) {
464
+ this._bMouseDown = false;
465
+ this._oEdgeInfo = null;
466
+ this._oBorderMoveInfo = null;
467
+ this._bScrollSelecting = false;
468
+ };
469
+
470
+ /**
471
+ * Checks if the given DOM reference is a selectable cell.
472
+ * @param {HTMLELement} oDomRef
473
+ * @returns {HTMLELement|null}
474
+ */
475
+ CellSelector.prototype._getSelectableCell = function (oDomRef) {
476
+ return oDomRef && oDomRef.closest(this.getConfig("selectableCells"));
477
+ };
478
+
238
479
  /**
239
480
  * Checks if the given target element is in the selection area.
240
481
  * @param {HTMLElement} oTarget target element
@@ -304,10 +545,18 @@ sap.ui.define([
304
545
  // "Select cells" - returns the area to draw on (boundaries), border information for drawing and selected cell information
305
546
  var oSelection = this.getConfig("selectCells", this.getControl(), mBounds, oOptions);
306
547
 
548
+ var mDrawableBounds = this._getDrawableBounds(mBounds);
549
+
550
+ if (!mDrawableBounds.from || !mDrawableBounds.to) {
551
+ // If there are no drawable bounds, do not continue.
552
+ return;
553
+ }
554
+
555
+ var oBorderOptions = this._getBorderOptions(mBounds, mDrawableBounds);
307
556
  this._oSession.aCells = oSelection.cells;
308
- this._drawSelection(oSelection.bounds, oSelection.borderOptions);
557
+ this._drawSelection(mDrawableBounds, oBorderOptions);
309
558
 
310
- if (oOptions && oOptions.info && !oOptions.info.boundaryChange) {
559
+ if (!oOptions.info || (oOptions.info && !oOptions.info.boundaryChange)) {
311
560
  // Set new source and target positions
312
561
  this._oSession.mSource = mFrom;
313
562
  this._oSession.mTarget = mTo;
@@ -318,6 +567,33 @@ sap.ui.define([
318
567
  }
319
568
  };
320
569
 
570
+ CellSelector.prototype._getDrawableBounds = function (mBounds) {
571
+ var mDrawableBounds = {from: {}, to: {}};
572
+
573
+ var mRange = this.getConfig("getVisibleRange", this.getControl(), mBounds); // from, to
574
+
575
+ if (mBounds.to.rowIndex < mRange.from.rowIndex || mBounds.from.rowIndex > mRange.to.rowIndex) {
576
+ mDrawableBounds = {};
577
+ } else {
578
+ mDrawableBounds.from.rowIndex = Math.max(mBounds.from.rowIndex, mRange.from.rowIndex);
579
+ mDrawableBounds.from.colIndex = Math.max(mBounds.from.colIndex, mRange.from.colIndex);
580
+ mDrawableBounds.to.rowIndex = Math.min(mBounds.to.rowIndex, mRange.to.rowIndex);
581
+ mDrawableBounds.to.colIndex = Math.min(mBounds.to.colIndex, mRange.to.colIndex);
582
+ }
583
+ return mDrawableBounds;
584
+ };
585
+
586
+ CellSelector.prototype._getBorderOptions = function (mBounds, mDrawableBounds) {
587
+ var oBorderOptions = {top: true, bottom: true};
588
+ if (mDrawableBounds.from.rowIndex > mBounds.from.rowIndex) {
589
+ oBorderOptions.top = false;
590
+ }
591
+ if (mDrawableBounds.to.rowIndex < mBounds.to.rowIndex) {
592
+ oBorderOptions.bottom = false;
593
+ }
594
+ return oBorderOptions;
595
+ };
596
+
321
597
  /**
322
598
  * Draws the selection for the given bounds.
323
599
  * @param {Object} mBounds object containing the bounds information (from, to)
@@ -326,6 +602,10 @@ sap.ui.define([
326
602
  * @private
327
603
  */
328
604
  CellSelector.prototype._drawSelection = function (mBounds, oOptions) {
605
+ if (!mBounds.from || !mBounds.to) {
606
+ return;
607
+ }
608
+
329
609
  var aSelectionAreas = this.getConfig("getSelectionAreas", this.getControl(), mBounds.from, mBounds.to);
330
610
 
331
611
  // Iterate through every selection area
@@ -361,6 +641,24 @@ sap.ui.define([
361
641
 
362
642
  // Draw selection area
363
643
  this._drawSelectionArea(oStyle, oArea.container);
644
+
645
+ // Draw Edge Handles
646
+ if (!this._oSession.oEdge[oArea.container]) {
647
+ this._oSession.oEdge[oArea.container] = {};
648
+ }
649
+ this._drawEdgeHandle(oStyle, oArea.container, "NE");
650
+ this._drawEdgeHandle(oStyle, oArea.container, "SE");
651
+ this._drawEdgeHandle(oStyle, oArea.container, "SW");
652
+ this._drawEdgeHandle(oStyle, oArea.container, "NW");
653
+
654
+ // Draw Border Lines
655
+ if (!this._oSession.oBorderLine[oArea.container]) {
656
+ this._oSession.oBorderLine[oArea.container] = {};
657
+ }
658
+ this._drawBorderLine(oStyle, oArea.container, "N");
659
+ this._drawBorderLine(oStyle, oArea.container, "E");
660
+ this._drawBorderLine(oStyle, oArea.container, "S");
661
+ this._drawBorderLine(oStyle, oArea.container, "W");
364
662
  }.bind(this));
365
663
  };
366
664
 
@@ -396,7 +694,58 @@ sap.ui.define([
396
694
  oStyle.borderLeft = oTargetStyle.noBorderLeft ? "0px" : "";
397
695
  };
398
696
 
399
- CellSelector.prototype._clearSelection = function () {
697
+ /**
698
+ * Draws the edge handles, which can be used to extend the cell selection in any direction.
699
+ * @param {object} oTargetStyle object containing style information
700
+ * @param {String} sContainer container name
701
+ * @param {String} sFacing direction of edge
702
+ * @private
703
+ */
704
+ CellSelector.prototype._drawEdgeHandle = function (oTargetStyle, sContainer, sFacing) {
705
+ if (!this._oSession.oEdge[sContainer][sFacing]) {
706
+ this._oSession.oEdge[sContainer][sFacing] = {};
707
+
708
+ this._oSession.oEdge[sContainer][sFacing].wrapper = document.createElement("div");
709
+ this._oSession.oEdge[sContainer][sFacing].wrapper.className = CSS_CLASS + "EdgeWrapper";
710
+ }
711
+ if (!this._oSession.oEdge[sContainer][sFacing].wrapper.isConnected) {
712
+ this._oSession.oCanvas[sContainer].append(this._oSession.oEdge[sContainer][sFacing].wrapper);
713
+ this._oSession.oEdge[sContainer][sFacing].wrapper.addEventListener("mousedown", this._onHandleMove.bind(this, sFacing, false));
714
+ }
715
+ this._oSession.oEdge[sContainer][sFacing].wrapper.classList.add("sapMPluginsEdge" + sFacing);
716
+ };
717
+
718
+ /**
719
+ * Draws a line for the border, which can be dragged to extend selection.
720
+ * @param {object} oTargetStyle object containing style information
721
+ * @param {String} sContainer container name
722
+ * @param {String} sFacing direction of border
723
+ * @private
724
+ */
725
+ CellSelector.prototype._drawBorderLine = function (oTargetStyle, sContainer, sFacing) {
726
+ if (!this._oSession.oBorderLine[sContainer][sFacing]) {
727
+ this._oSession.oBorderLine[sContainer][sFacing] = document.createElement("div");
728
+ this._oSession.oBorderLine[sContainer][sFacing].className = CSS_CLASS + "BorderLine";
729
+ }
730
+ if (!this._oSession.oBorderLine[sContainer][sFacing].isConnected) {
731
+ this._oSession.oCanvas[sContainer].append(this._oSession.oBorderLine[sContainer][sFacing]);
732
+ this._oSession.oBorderLine[sContainer][sFacing].addEventListener("mousedown", this._onHandleMove.bind(this, sFacing, true));
733
+ }
734
+
735
+ var oStyle = this._oSession.oBorderLine[sContainer][sFacing].style;
736
+ this._oSession.oBorderLine[sContainer][sFacing].classList.add("sapMPluginsBorder" + sFacing);
737
+ if (sFacing === "N" || sFacing === "S") {
738
+ oStyle.width = oTargetStyle.width + "px";
739
+ } else {
740
+ oStyle.height = oTargetStyle.height + "px";
741
+ }
742
+ oStyle.display = "block";
743
+ };
744
+
745
+ /**
746
+ * Clears the currently selected cells.
747
+ */
748
+ CellSelector.prototype.clearSelection = function () {
400
749
  this._bSelecting = false;
401
750
  this._eraseSelection();
402
751
  this._oSession.mSource = null;
@@ -411,6 +760,18 @@ sap.ui.define([
411
760
  Object.values(this._oSession.oCanvas).forEach(function (oArea) {
412
761
  oArea.style = "";
413
762
  });
763
+ Object.values(this._oSession.oBorderLine).forEach(function (oArea) {
764
+ Object.values(oArea).forEach(function (oBorder) {
765
+ oBorder.style = "";
766
+ });
767
+ });
768
+ Object.values(this._oSession.oEdge).forEach(function (oArea) {
769
+ Object.values(oArea).forEach(function (oEdge) {
770
+ Object.values(oEdge).forEach(function (oEdgePart) {
771
+ oEdgePart.style = "";
772
+ });
773
+ });
774
+ });
414
775
  };
415
776
 
416
777
  /**
@@ -447,6 +808,32 @@ sap.ui.define([
447
808
  }.bind(this));
448
809
  };
449
810
 
811
+ /**
812
+ * Retrieves the current mouse position and returns info on whether the mouse is inside the control or not.
813
+ * @param {String} sContainer container name
814
+ * @param {number} iX x position of mouse
815
+ * @param {y} iY y position of mouse
816
+ * @returns {object} object containing position information for x, y
817
+ */
818
+ CellSelector.prototype._getMousePosition = function (sContainer, iX, iY) {
819
+ var oContainerRef = this.getControl().getDomRef(sContainer);
820
+ var oPosition = {x: MOUSE_POSITION.IN, y: MOUSE_POSITION.IN};
821
+ if (oContainerRef) {
822
+ var oContainerRect = oContainerRef.getBoundingClientRect();
823
+ if (iY > oContainerRect.bottom) {
824
+ oPosition.y = MOUSE_POSITION.BELOW;
825
+ } else if (iY < oContainerRect.top) {
826
+ oPosition.y = MOUSE_POSITION.ABOVE;
827
+ }
828
+ if (iX > oContainerRect.right) {
829
+ oPosition.x = MOUSE_POSITION.RIGHT;
830
+ } else if (iX < oContainerRect.left) {
831
+ oPosition.x = MOUSE_POSITION.LEFT;
832
+ }
833
+ }
834
+ return oPosition;
835
+ };
836
+
450
837
  /**
451
838
  * Returns an object containing normalized coordinates for the given bounding area.
452
839
  * <code>from</code> will contain the coordinates for the upper left corner of the bounding area,
@@ -479,13 +866,34 @@ sap.ui.define([
479
866
  }
480
867
 
481
868
  PluginBase.setConfigs({
482
- "sap.m.Table": {
483
- selectableCells: ".sapMListTblCell:not([aria-hidden=true])"
484
- },
485
869
  "sap.ui.table.Table": {
486
- container: "tableCtrlCnt",
870
+ container: "tableCCnt",
871
+ scrollContainer: "sapUiTableCtrlScr",
487
872
  selectableCells: ".sapUiTableDataCell",
488
873
  scrollEvent: "firstVisibleRowChanged",
874
+ onActivate: function (oControl, oPlugin) {
875
+ var sEvent = "rowSelectionChange";
876
+ var oSelectionPlugin = oControl;
877
+ oControl.getPlugins().forEach(function (oPlugin) {
878
+ if (oPlugin.isA("sap.ui.table.plugins.SelectionPlugin")) {
879
+ sEvent = "selectionChange";
880
+ oSelectionPlugin = oPlugin;
881
+ }
882
+ });
883
+ oSelectionPlugin.attachEvent(sEvent, oPlugin.clearSelection, oPlugin);
884
+ },
885
+ onDeactivate: function (oControl, oPlugin) {
886
+ var sEvent = "rowSelectionChange";
887
+ var oSelectionPlugin = oControl;
888
+ oControl.getPlugins().forEach(function (oPlugin) {
889
+ if (oPlugin.isA("sap.ui.table.plugins.SelectionPlugin")) {
890
+ sEvent = "selectionChange";
891
+ oSelectionPlugin = oPlugin;
892
+ return;
893
+ }
894
+ });
895
+ oSelectionPlugin.detachEvent(sEvent, oPlugin.clearSelection, oPlugin);
896
+ },
489
897
  /**
490
898
  * Checks if the selection is enabled for the control.
491
899
  * @param {sap.ui.core.Control} oControl control instance
@@ -508,7 +916,7 @@ sap.ui.define([
508
916
  var oColumn = this._getColumns(oTable)[mPosition.colIndex];
509
917
  var oCell = oColumn && oRow.getCells()[mPosition.colIndex];
510
918
  if (oCell) {
511
- return oCell.$().closest(".sapUiTableDataCell")[0];
919
+ return oCell.$().closest(this.selectableCells)[0];
512
920
  }
513
921
  }
514
922
  },
@@ -524,6 +932,18 @@ sap.ui.define([
524
932
  colIndex: this.colIndex(oTable, oTarget)
525
933
  };
526
934
  },
935
+ /**
936
+ * Retrieve the visible row range for the given table.
937
+ * @param {sap.ui.table.Table} oTable table instance
938
+ * @returns {Object} object containing from - to table range
939
+ */
940
+ getVisibleRange: function (oTable) {
941
+ var aRows = oTable.getRows();
942
+ return {
943
+ from: {rowIndex: aRows[0].getIndex(), colIndex: 0},
944
+ to: {rowIndex: aRows[aRows.length - 1].getIndex(), colIndex: this._getColumns(oTable).length - 1}
945
+ };
946
+ },
527
947
  /**
528
948
  * Returns the controls' available selection areas for the given bounds.
529
949
  *
@@ -544,15 +964,13 @@ sap.ui.define([
544
964
  aAreas.push({container: "sapUiTableCtrlScrFixed", from: mFixedFrom, to: mFixedTo});
545
965
  }
546
966
  if (mTo.colIndex >= iFixedColumnCount || mTo.colIndex === Infinity) {
547
- aAreas.push({container: this.container, from: mFrom, to: mTo, hasOffset: true});
967
+ aAreas.push({container: "tableCtrlCnt", from: mFrom, to: mTo, hasOffset: true});
548
968
  }
549
969
  return aAreas;
550
970
  },
551
971
  /**
552
972
  * Retrieves selected cells and returns their position and the boundaries of the selection area fitted to the table and its border options.
553
973
  *
554
- * Note: Also modifies the original mSelectionBounds object and replaces MIN/MAX with real values.
555
- *
556
974
  * Note: As the selection area may vary based on control-specific settings (e.g. SingleSelection), the information is returned as well.
557
975
  * @param {sap.ui.table.Table} oTable table instance
558
976
  * @param {Object} mSelectionBounds selection options
@@ -563,83 +981,41 @@ sap.ui.define([
563
981
  */
564
982
  selectCells: function (oTable, mSelectionBounds, oOptions) {
565
983
  var mBounds = {}, oBorderOptions = {top: true, bottom: true};
984
+ var iBindingLength = oTable.getBinding("rows").getLength();
566
985
  mBounds.from = Object.assign({}, mSelectionBounds.from);
567
986
  mBounds.to = Object.assign({}, mSelectionBounds.to);
987
+
988
+ mBounds.from.rowIndex = Math.max(mBounds.from.rowIndex, 0);
989
+ mBounds.from.colIndex = Math.max(mBounds.from.colIndex, 0);
990
+
991
+ mBounds.to.rowIndex = Math.min(mBounds.to.rowIndex, iBindingLength);
992
+ mBounds.to.colIndex = Math.min(mBounds.to.colIndex, this._getColumns(oTable).length - 1);
993
+
568
994
  var aCells = [];
569
995
 
570
996
  // Replace MIN/MAX with according number for focus object
571
997
  if (oOptions && oOptions.info) {
572
- if (oOptions.info.focus.rowIndex === -Infinity) {
573
- oOptions.info.focus.rowIndex = 0;
574
- } else if (oOptions.info.focus.rowIndex === Infinity) {
575
- oOptions.info.focus.rowIndex = oTable._getTotalRowCount();
576
- }
577
- if (oOptions.info.focus.colIndex === -Infinity) {
578
- oOptions.info.focus.colIndex = 0;
579
- } else if (oOptions.info.focus.colIndex === Infinity) {
580
- oOptions.info.focus.colIndex = this._getColumns(oTable).length - 1;
581
- }
998
+ oOptions.info.focus.rowIndex = Math.min(Math.max(oOptions.info.focus.rowIndex, 0), iBindingLength);
999
+ oOptions.info.focus.colIndex = Math.min(Math.max(oOptions.info.focus.colIndex, 0), this._getColumns(oTable).length - 1);
582
1000
  this._focusCell(oTable, oOptions.info.focus, oOptions.info.direction);
583
1001
  }
584
1002
 
585
- // Determine the first, last and last row of unfixed rows. Needs to factor in fixed rows.
586
- var iFirstRow = oTable.getFirstVisibleRow() + oTable.getFixedRowCount();
587
- var iLastRowIndex = iFirstRow + oTable.getVisibleRowCount() - oTable.getFixedBottomRowCount() - oTable.getFixedRowCount() - 1;
588
- var iLowerFixedLimit = iFirstRow + oTable.getVisibleRowCount() - oTable.getFixedRowCount() - oTable.getFixedBottomRowCount();
589
-
590
- if ((mBounds.from.rowIndex < iFirstRow && mBounds.to.rowIndex < iFirstRow
591
- || mBounds.from.rowIndex > iLastRowIndex && mBounds.to.rowIndex > iLastRowIndex)
592
- && !(mBounds.from.rowIndex < oTable.getFixedRowCount() || mBounds.to.rowIndex >= iLowerFixedLimit)) {
593
- // If both FROM and TO are out of the view port and there is no need to render them, set bounds to none. Needs to factor in fixed rows.
594
- mBounds.from = {};
595
- mBounds.to = {};
596
- } else {
597
- if ((mBounds.from.rowIndex < iFirstRow && mBounds.from.rowIndex > (oTable.getFixedRowCount() - 1)) || mBounds.from.rowIndex === -Infinity) {
598
- // Case 1: FROM is "above" table, so return the position of the first row instead for rendering.
599
- mBounds.from.rowIndex = iFirstRow;
600
- oBorderOptions.top = mBounds.from.rowIndex == 0 ? true : false;
601
- if (mSelectionBounds.from.rowIndex === -Infinity) {
602
- // Case 1.A: If MIN is given, set it immediately to 0
603
- mSelectionBounds.from.rowIndex = 0;
604
- mBounds.from.rowIndex = oTable.getFixedRowCount() > 0 ? 0 : iFirstRow;
605
- }
606
- }
607
- if ((mBounds.to.rowIndex > iLastRowIndex && mBounds.to.rowIndex < (oTable._getTotalRowCount() - oTable.getFixedBottomRowCount())) || mBounds.to.rowIndex === Infinity) {
608
- // Case 2: TO is "below" table (currently visible rows), so return the position of the last visible row instead for rendering.
609
- mBounds.to.rowIndex = iLastRowIndex;
610
- oBorderOptions.bottom = mBounds.to.rowIndex == oTable._getTotalRowCount() - 1 ? true : false;
611
- if (mSelectionBounds.to.rowIndex === Infinity) {
612
- // Case 2.A: If MAX is given, set it immediately to the maximum row count
613
- mSelectionBounds.to.rowIndex = oTable._getTotalRowCount() - 1;
614
- mBounds.to.rowIndex = oTable.getFixedRowCount() > 0 ? oTable._getTotalRowCount() - 1 : iLastRowIndex;
615
- }
616
- }
617
- }
618
-
619
1003
  // If table is in Single Selection Mode, only select the row with focus in it
620
- if (mBounds.from.colIndex === -Infinity && mBounds.from.colIndex === Infinity) {
621
- mBounds.from.rowIndex = oOptions.info.focus.rowIndex;
622
- mSelectionBounds.from.rowIndex = oOptions.info.focus.rowIndex;
1004
+ if (mBounds.from.colIndex === 0 && mBounds.to.colIndex === (this._getColumns(oTable).length - 1) && oTable.getSelectionMode() == "Single") {
1005
+ mBounds.from.rowIndex = mSelectionBounds.from.rowIndex = oOptions.info.focus.rowIndex;
1006
+ mBounds.to.rowIndex = mSelectionBounds.to.rowIndex = oOptions.info.focus.rowIndex;
623
1007
  }
624
1008
 
625
- var aVisibleColumns = this._getColumns(oTable);
626
- mBounds.from.colIndex = mSelectionBounds.from.colIndex = Math.max(mSelectionBounds.from.colIndex, 0);
627
- mBounds.to.colIndex = mSelectionBounds.to.colIndex = Math.min(mSelectionBounds.to.colIndex, aVisibleColumns.length - 1);
628
-
629
- for (var iRow = mSelectionBounds.from.rowIndex; iRow <= mSelectionBounds.to.rowIndex; iRow++) {
1009
+ for (var iRow = mBounds.from.rowIndex; iRow <= mBounds.to.rowIndex; iRow++) {
630
1010
  var oRow = this._getRowByIndex(oTable, iRow);
631
1011
  if (oRow) {
632
- for (var iCol = mSelectionBounds.from.colIndex; iCol <= mSelectionBounds.to.colIndex; iCol++) {
1012
+ for (var iCol = mBounds.from.colIndex; iCol <= mBounds.to.colIndex; iCol++) {
633
1013
  aCells.push([iRow, iCol]);
634
1014
  }
635
1015
  }
636
1016
  }
637
1017
 
638
- return {
639
- bounds: mBounds,
640
- borderOptions: oBorderOptions,
641
- cells: aCells
642
- };
1018
+ return {borderOptions: oBorderOptions, cells: aCells};
643
1019
  },
644
1020
  /**
645
1021
  * Retrieves the row index for the given cell's DOM reference.
@@ -670,8 +1046,10 @@ sap.ui.define([
670
1046
  return oColumn;
671
1047
  },
672
1048
  isNavigatableCell: function (oTable, mPosition) {
673
- if (mPosition.rowIndex < 0 || mPosition.rowIndex >= oTable._getTotalRowCount()
674
- || mPosition.colIndex < 0 || mPosition.colIndex >= this._getColumns(oTable).length) {
1049
+ if ((mPosition.rowIndex < 0 || mPosition.rowIndex >= oTable.getBinding("rows").getLength()
1050
+ || mPosition.colIndex < 0 || mPosition.colIndex >= this._getColumns(oTable).length)
1051
+ && !(mPosition.rowIndex == -Infinity || mPosition.rowIndex == Infinity
1052
+ || mPosition.colIndex == -Infinity || mPosition.colIndex == Infinity)) {
675
1053
  return false;
676
1054
  }
677
1055
  return true;
@@ -684,11 +1062,12 @@ sap.ui.define([
684
1062
  */
685
1063
  _scrollRow: function (oTable, iDirection, iRow) {
686
1064
  var iFirstRow = oTable.getFirstVisibleRow();
687
- if (iRow >= 0 && iRow < oTable._getTotalRowCount()) {
1065
+ if (iRow >= 0 && iRow < oTable.getBinding("rows").getLength()) {
688
1066
  if (oTable.getFixedRowCount() > 0 && iRow == oTable.getFixedRowCount()) {
689
1067
  oTable.setFirstVisibleRow(0);
690
1068
  } else {
691
1069
  iDirection == SELECTION_DIRECTION.NEXT ? iFirstRow++ : iFirstRow--;
1070
+ iFirstRow = iFirstRow < 0 ? 0 : iFirstRow;
692
1071
  oTable.setFirstVisibleRow(iFirstRow);
693
1072
  }
694
1073
  }
@@ -707,6 +1086,10 @@ sap.ui.define([
707
1086
  if (!oCellRef) {
708
1087
  this._scrollRow(oTable, iDirection, mPosition.rowIndex);
709
1088
  oCellRef = this.getCellRef(oTable, mPosition);
1089
+ if (!oCellRef) {
1090
+ oTable.setFirstVisibleRow(mPosition.rowIndex);
1091
+ oCellRef = this.getCellRef(oTable, mPosition);
1092
+ }
710
1093
  }
711
1094
  oCellRef && oCellRef.focus();
712
1095
  },
@@ -717,7 +1100,7 @@ sap.ui.define([
717
1100
  */
718
1101
  _getColumns: function (oTable) {
719
1102
  return oTable.getColumns().filter(function (oColumn) {
720
- return oColumn.shouldRender();
1103
+ return oColumn.getDomRef();
721
1104
  });
722
1105
  },
723
1106
  /**