Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

fix(web-components-wrapper): don't generate default props for empty strings #469

Merged
merged 3 commits into from
May 4, 2020

Conversation

MarcusNotheis
Copy link
Contributor

Empty strings, e.g. from default props might lead to unintended behavior, e.g. showing a popover header although it was not defined.

Empty strings, e.g. from default props might lead to unintended behavior, e.g. showing a popover header although it was not defined.
@github-actions
Copy link

github-actions bot commented May 3, 2020

Coverage Status

Coverage increased (+0.05%) to 66.86% when pulling d3a9f2f on fix/with-web-component-empty-strings into b21b1f0 on master.

@github-actions
Copy link

github-actions bot commented May 3, 2020

Size Change: -433 B (0%)

Total Size: 221 kB

Filename Size Change
packages/main/lib/Avatar.js 438 B -18 B (4%)
packages/main/lib/BusyIndicator.js 357 B -6 B (1%)
packages/main/lib/Button.js 370 B -6 B (1%)
packages/main/lib/Calendar.js 348 B -14 B (4%)
packages/main/lib/Card.js 342 B -16 B (4%)
packages/main/lib/CheckBox.js 388 B -10 B (2%)
packages/main/lib/ComboBox.js 431 B -12 B (2%)
packages/main/lib/ComboBoxItem.js 311 B -7 B (2%)
packages/main/lib/DatePicker.js 459 B -22 B (4%)
packages/main/lib/DateTimePicker.js 467 B -23 B (4%)
packages/main/lib/Dialog.js 364 B -12 B (3%)
packages/main/lib/FileUploader.js 401 B -21 B (5%)
packages/main/lib/Icon.js 328 B -9 B (2%)
packages/main/lib/Input.js 465 B -14 B (3%)
packages/main/lib/Label.js 341 B -7 B (2%)
packages/main/lib/Link.js 359 B -9 B (2%)
packages/main/lib/List.js 439 B -16 B (3%)
packages/main/lib/MultiComboBox.js 438 B -11 B (2%)
packages/main/lib/MultiComboBoxItem.js 330 B -7 B (2%)
packages/main/lib/Panel.js 399 B -5 B (1%)
packages/main/lib/Popover.js 487 B -12 B (2%)
packages/main/lib/ProductSwitchItem.js 359 B -20 B (5%)
packages/main/lib/RadioButton.js 397 B -17 B (4%)
packages/main/lib/ResponsivePopover.js 502 B -12 B (2%)
packages/main/lib/Select.js 352 B -6 B (1%)
packages/main/lib/ShellBar.js 447 B -18 B (4%)
packages/main/lib/ShellBarItem.js 335 B -16 B (4%)
packages/main/lib/SuggestionItem.js 386 B -7 B (1%)
packages/main/lib/Switch.js 351 B -8 B (2%)
packages/main/lib/Tab.js 372 B -13 B (3%)
packages/main/lib/Table.js 365 B -5 B (1%)
packages/main/lib/TableColumn.js 352 B -7 B (1%)
packages/main/lib/TextArea.js 469 B -14 B (2%)
packages/main/lib/TimelineItem.js 351 B -19 B (5%)
packages/main/lib/TimePicker.js 411 B -7 B (1%)
packages/main/lib/ToggleButton.js 391 B -6 B (1%)
packages/main/lib/UploadCollection.js 398 B -9 B (2%)
packages/main/lib/UploadCollectionItem.js 449 B -7 B (1%)
packages/main/lib/withWebComponent.js 2.63 kB +15 B (0%)
ℹ️ View Unchanged
Filename Size Change
packages/base/lib/createComponentStyles.js 206 B 0 B
packages/base/lib/CssSizeVariables.js 1.16 kB 0 B
packages/base/lib/Device.js 7.28 kB 0 B
packages/base/lib/Event.js 966 B 0 B
packages/base/lib/font72.js 447 B 0 B
packages/base/lib/hooks.js 2.1 kB 0 B
packages/base/lib/HSLColor.js 2.87 kB 0 B
packages/base/lib/Logger.js 1.41 kB 0 B
packages/base/lib/Optional.js 1.48 kB 0 B
packages/base/lib/sap_fiori_3.js 6.69 kB 0 B
packages/base/lib/ScrollContext.js 232 B 0 B
packages/base/lib/Scroller.js 3.31 kB 0 B
packages/base/lib/ScrollLink.js 601 B 0 B
packages/base/lib/spacing.js 1.23 kB 0 B
packages/base/lib/StyleClassHelper.js 1.62 kB 0 B
packages/base/lib/ThemingParameters.js 3.4 kB 0 B
packages/base/lib/useConsolidatedRef.js 271 B 0 B
packages/base/lib/usePassThroughHtmlProps.js 765 B 0 B
packages/base/lib/useScrollElement.js 727 B 0 B
packages/base/lib/useViewportRange.js 1.07 kB 0 B
packages/base/lib/Utils.js 1.12 kB 0 B
packages/charts/lib/BarChart.js 4.97 kB 0 B
packages/charts/lib/BarChartPlaceholder.js 456 B 0 B
packages/charts/lib/ColumnChart.js 5.11 kB 0 B
packages/charts/lib/ColumnChartPlaceholder.js 495 B 0 B
packages/charts/lib/components/ChartDataLabel.js 3.6 kB 0 B
packages/charts/lib/components/ComposedChartPlaceholder.js 878 B 0 B
packages/charts/lib/components/XAxisTicks.js 1.56 kB 0 B
packages/charts/lib/components/YAxisTicks.js 656 B 0 B
packages/charts/lib/DonutChart.js 3.47 kB 0 B
packages/charts/lib/LineChart.js 4.64 kB 0 B
packages/charts/lib/LineChartPlaceholder.js 510 B 0 B
packages/charts/lib/MicroBarChart.js 2.92 kB 0 B
packages/charts/lib/next/BarChart.js 3.99 kB 0 B
packages/charts/lib/next/ChartContainer.js 1.08 kB 0 B
packages/charts/lib/next/ColumnChart.js 4.12 kB 0 B
packages/charts/lib/next/ComposedChart.js 5.49 kB 0 B
packages/charts/lib/next/DonutChart.js 2.01 kB 0 B
packages/charts/lib/next/LineChart.js 4.05 kB 0 B
packages/charts/lib/next/MicroBarChart.js 2.26 kB 0 B
packages/charts/lib/next/PieChart.js 1.9 kB 0 B
packages/charts/lib/next/RadarChart.js 2.18 kB 0 B
packages/charts/lib/next/RadialChart.js 1.1 kB 0 B
packages/charts/lib/PieChart.js 3.43 kB 0 B
packages/charts/lib/PieChartPlaceholder.js 427 B 0 B
packages/charts/lib/RadarChart.js 3.11 kB 0 B
packages/charts/lib/RadialChart.js 4.01 kB 0 B
packages/charts/lib/useLegendItemClick.js 391 B 0 B
packages/charts/lib/withChartContainer.js 2.91 kB 0 B
packages/main/lib/ActionSheet.js 1.24 kB 0 B
packages/main/lib/AnalyticalCard.js 1.21 kB 0 B
packages/main/lib/AnalyticalCardHeader.js 2.94 kB 0 B
packages/main/lib/AnalyticalTable.js 16.8 kB 0 B
packages/main/lib/AnalyticalTableScrollMode.js 185 B 0 B
packages/main/lib/AvatarBackgroundColor.js 219 B 0 B
packages/main/lib/AvatarFitType.js 151 B 0 B
packages/main/lib/AvatarShape.js 150 B 0 B
packages/main/lib/AvatarSize.js 155 B 0 B
packages/main/lib/Badge.js 320 B 0 B
packages/main/lib/Bar.js 1.34 kB 0 B
packages/main/lib/BarDesign.js 177 B 0 B
packages/main/lib/Breadcrumbs.js 722 B 0 B
packages/main/lib/BreadcrumbsSeparatorStyle.js 198 B 0 B
packages/main/lib/BusyIndicatorSize.js 167 B 0 B
packages/main/lib/ButtonDesign.js 190 B 0 B
packages/main/lib/CalendarType.js 212 B 0 B
packages/main/lib/Carousel.js 418 B 0 B
packages/main/lib/CarouselArrowsPlacement.js 166 B 0 B
packages/main/lib/ContentDensity.js 151 B 0 B
packages/main/lib/CurrentViewportRangeContext.js 133 B 0 B
packages/main/lib/CustomListItem.js 355 B 0 B
packages/main/lib/DeviationIndicator.js 160 B 0 B
packages/main/lib/DurationPicker.js 398 B 0 B
packages/main/lib/FilterBar.js 2.04 kB 0 B
packages/main/lib/FilterItem.js 1.55 kB 0 B
packages/main/lib/FilterType.js 170 B 0 B
packages/main/lib/FlexBox.js 1.09 kB 0 B
packages/main/lib/FlexBoxAlignItems.js 189 B 0 B
packages/main/lib/FlexBoxDirection.js 169 B 0 B
packages/main/lib/FlexBoxJustifyContent.js 194 B 0 B
packages/main/lib/FlexBoxWrap.js 154 B 0 B
packages/main/lib/Form.js 1.75 kB 0 B
packages/main/lib/FormGroup.js 559 B 0 B
packages/main/lib/FormItem.js 1.55 kB 0 B
packages/main/lib/GlobalStyleClasses.js 151 B 0 B
packages/main/lib/Grid.js 3.73 kB 0 B
packages/main/lib/GridPosition.js 157 B 0 B
packages/main/lib/GroupHeaderListItem.js 333 B 0 B
packages/main/lib/InputType.js 184 B 0 B
packages/main/lib/LinkDesign.js 191 B 0 B
packages/main/lib/ListItemTypes.js 160 B 0 B
packages/main/lib/ListMode.js 191 B 0 B
packages/main/lib/ListSeparators.js 186 B 0 B
packages/main/lib/Loader.js 2.18 kB 0 B
packages/main/lib/LoaderType.js 152 B 0 B
packages/main/lib/MessageBox.js 2.01 kB 0 B
packages/main/lib/MessageBoxActions.js 231 B 0 B
packages/main/lib/MessageBoxTypes.js 232 B 0 B
packages/main/lib/MessageStrip.js 371 B 0 B
packages/main/lib/MessageStripType.js 181 B 0 B
packages/main/lib/Notification.js 4.25 kB 0 B
packages/main/lib/NotificationGroup.js 321 B 0 B
packages/main/lib/ObjectPage.js 10.2 kB 0 B
packages/main/lib/ObjectPageMode.js 159 B 0 B
packages/main/lib/ObjectPageSection.js 2.2 kB 0 B
packages/main/lib/ObjectPageSubSection.js 2.04 kB 0 B
packages/main/lib/ObjectStatus.js 1.2 kB 0 B
packages/main/lib/Option.js 324 B 0 B
packages/main/lib/Page.js 2.08 kB 0 B
packages/main/lib/PageBackgroundDesign.js 183 B 0 B
packages/main/lib/PanelAccessibleRoles.js 201 B 0 B
packages/main/lib/PlacementType.js 175 B 0 B
packages/main/lib/PopoverHorizontalAlign.js 181 B 0 B
packages/main/lib/PopoverPlacementType.js 172 B 0 B
packages/main/lib/PopoverVerticalAlign.js 204 B 0 B
packages/main/lib/Priority.js 163 B 0 B
packages/main/lib/ProductSwitch.js 308 B 0 B
packages/main/lib/ProgressIndicator.js 1.79 kB 0 B
packages/main/lib/SegmentedButton.js 321 B 0 B
packages/main/lib/SemanticColor.js 181 B 0 B
packages/main/lib/SideNavigation.js 2.06 kB 0 B
packages/main/lib/SideNavigationListItem.js 3.05 kB 0 B
packages/main/lib/SideNavigationOpenState.js 174 B 0 B
packages/main/lib/Size.js 151 B 0 B
packages/main/lib/Spinner.js 1.75 kB 0 B
packages/main/lib/StandardListItem.js 417 B 0 B
packages/main/lib/TabContainer.js 412 B 0 B
packages/main/lib/TabContainerTabsPlacement.js 161 B 0 B
packages/main/lib/TabLayout.js 150 B 0 B
packages/main/lib/TableCell.js 303 B 0 B
packages/main/lib/TablePlaceholder.js 1.12 kB 0 B
packages/main/lib/TableRow.js 302 B 0 B
packages/main/lib/TableScaleWidthMode.js 169 B 0 B
packages/main/lib/TableSelectionBehavior.js 178 B 0 B
packages/main/lib/TableSelectionMode.js 182 B 0 B
packages/main/lib/TabSeparator.js 306 B 0 B
packages/main/lib/Text.js 846 B 0 B
packages/main/lib/TextAlign.js 183 B 0 B
packages/main/lib/ThemeProvider.js 1.14 kB 0 B
packages/main/lib/Themes.js 178 B 0 B
packages/main/lib/Timeline.js 298 B 0 B
packages/main/lib/Title.js 337 B 0 B
packages/main/lib/TitleLevel.js 163 B 0 B
packages/main/lib/Toast.js 349 B 0 B
packages/main/lib/ToastPlacement.js 208 B 0 B
packages/main/lib/Token.js 233 B 0 B
packages/main/lib/Tokenizer.js 248 B 0 B
packages/main/lib/UploadState.js 170 B 0 B
packages/main/lib/ValueState.js 182 B 0 B
packages/main/lib/VariantManagement.js 2.78 kB 0 B
packages/main/lib/VerticalAlign.js 174 B 0 B

compressed-size-action

@MarcusNotheis MarcusNotheis requested review from vbersch and Lukas742 May 4, 2020 05:50
@MarcusNotheis MarcusNotheis changed the title fix(withWebComponent): filter out empty strings fix(web-components-wrapper): don't generate default props for empty strings May 4, 2020
@MarcusNotheis MarcusNotheis requested a review from Lukas742 May 4, 2020 07:11
@MarcusNotheis MarcusNotheis merged commit 48505d9 into master May 4, 2020
@MarcusNotheis MarcusNotheis deleted the fix/with-web-component-empty-strings branch May 4, 2020 07:19
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants