@skyscanner/backpack-web 25.7.0-beta → 25.7.0-beta.2
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.
- package/bpk-animate-height/index.js +2 -3
- package/bpk-animate-height/src/AnimateHeight.js +36 -53
- package/bpk-component-accordion/index.js +5 -15
- package/bpk-component-accordion/src/BpkAccordion.js +28 -38
- package/bpk-component-accordion/src/BpkAccordionItem.js +67 -104
- package/bpk-component-accordion/src/withAccordionItemState.js +26 -51
- package/bpk-component-accordion/src/withSingleItemAccordionState.js +29 -55
- package/bpk-component-aria-live/index.js +21 -0
- package/bpk-component-aria-live/src/{BpkAriaLive.tsx → BpkAriaLive.js} +12 -30
- package/bpk-component-autosuggest/index.js +3 -8
- package/bpk-component-autosuggest/src/BpkAutosuggest.js +23 -36
- package/bpk-component-autosuggest/src/BpkAutosuggestSuggestion.js +43 -65
- package/bpk-component-badge/index.js +22 -0
- package/bpk-component-badge/src/{BpkBadge.tsx → BpkBadge.js} +13 -36
- package/{bpk-component-button/src/BpkButtonLink.module.scss → bpk-component-badge/src/themeAttributes.js} +1 -7
- package/bpk-component-banner-alert/index.js +26 -0
- package/bpk-component-banner-alert/src/{AnimateAndFade.tsx → AnimateAndFade.js} +57 -89
- package/bpk-component-banner-alert/src/{BpkBannerAlert.tsx → BpkBannerAlert.js} +11 -16
- package/{bpk-component-badge/src/themeAttributes-test.tsx → bpk-component-banner-alert/src/BpkBannerAlertDismissable.js} +10 -10
- package/{bpk-component-badge/src/accessibility-test.tsx → bpk-component-banner-alert/src/BpkBannerAlertExpandable.js} +14 -11
- package/bpk-component-banner-alert/src/BpkBannerAlertInner.js +178 -0
- package/{bpk-component-accordion/src/BpkAccordion.module.scss → bpk-component-banner-alert/src/common-types.js} +7 -9
- package/{bpk-component-badge/src/themeAttributes.tsx → bpk-component-banner-alert/src/themeAttributes.js} +1 -5
- package/bpk-component-banner-alert/src/{withBannerAlertState.tsx → withBannerAlertState.js} +33 -78
- package/bpk-component-barchart/index.js +8 -21
- package/bpk-component-barchart/src/BpkBarchart.js +105 -196
- package/bpk-component-barchart/src/BpkBarchartBar.js +44 -86
- package/bpk-component-barchart/src/BpkBarchartBars.js +68 -91
- package/bpk-component-barchart/src/BpkBarchartDefs.js +29 -26
- package/bpk-component-barchart/src/BpkChartAxis.js +57 -101
- package/bpk-component-barchart/src/BpkChartDataTable.js +40 -48
- package/bpk-component-barchart/src/BpkChartGridLines.js +34 -69
- package/bpk-component-barchart/src/BpkChartMargin.js +17 -28
- package/bpk-component-barchart/src/RTLtransforms.js +11 -28
- package/bpk-component-barchart/src/customPropTypes.js +9 -26
- package/bpk-component-barchart/src/orientation.js +2 -6
- package/bpk-component-barchart/src/themeAttributes.js +1 -10
- package/bpk-component-barchart/src/utils.js +6 -14
- package/bpk-component-blockquote/index.js +3 -4
- package/bpk-component-blockquote/src/BpkBlockquote.js +12 -21
- package/bpk-component-blockquote/src/themeAttributes.js +1 -1
- package/{bpk-component-graphic-promotion/index.ts → bpk-component-boilerplate/index.d.ts} +5 -7
- package/{bpk-component-drawer/src/BpkDrawer.module.scss → bpk-component-boilerplate/index.js} +2 -5
- package/{bpk-component-nudger/src/common-types.ts → bpk-component-boilerplate/src/BpkBoilerplate.d.ts} +10 -10
- package/{bpk-component-aria-live/src/accessibility-test.tsx → bpk-component-boilerplate/src/BpkBoilerplate.js} +15 -11
- package/{bpk-component-icon/src/withDescription.module.scss → bpk-component-boilerplate/src/BpkBoilerplate.module.css} +6 -10
- package/bpk-component-breadcrumb/index.js +3 -14
- package/bpk-component-breadcrumb/src/BpkBreadcrumb.js +41 -65
- package/bpk-component-breadcrumb/src/BpkBreadcrumbItem.js +45 -59
- package/bpk-component-breakpoint/{index.ts → index.js} +2 -3
- package/bpk-component-breakpoint/src/{BpkBreakpoint.tsx → BpkBreakpoint.js} +14 -18
- package/bpk-component-button/BpkButtonDestructive.js +1 -5
- package/bpk-component-button/BpkButtonFeatured.js +1 -5
- package/bpk-component-button/BpkButtonLink.js +1 -5
- package/bpk-component-button/BpkButtonLinkOnDark.js +1 -5
- package/bpk-component-button/BpkButtonPrimary.js +1 -5
- package/bpk-component-button/BpkButtonPrimaryOnDark.js +1 -5
- package/bpk-component-button/BpkButtonPrimaryOnLight.js +1 -5
- package/bpk-component-button/BpkButtonSecondary.js +1 -5
- package/bpk-component-button/BpkButtonSecondaryOnDark.js +1 -5
- package/bpk-component-button/index.js +14 -42
- package/bpk-component-button/src/BpkButton.js +35 -54
- package/bpk-component-button/src/BpkButtonBase.js +32 -48
- package/bpk-component-button/src/BpkButtonDestructive.js +21 -20
- package/bpk-component-button/src/BpkButtonFeatured.js +21 -20
- package/bpk-component-button/src/BpkButtonLink.js +23 -24
- package/bpk-component-button/src/BpkButtonLinkOnDark.js +23 -24
- package/bpk-component-button/src/BpkButtonPrimary.js +13 -12
- package/bpk-component-button/src/BpkButtonPrimaryOnDark.js +21 -20
- package/bpk-component-button/src/BpkButtonPrimaryOnLight.js +21 -20
- package/bpk-component-button/src/BpkButtonSecondary.js +21 -20
- package/bpk-component-button/src/BpkButtonSecondaryOnDark.js +21 -20
- package/bpk-component-button/src/BpkButtonV2/{BpkButton.tsx → BpkButton.js} +24 -44
- package/bpk-component-button/src/BpkButtonV2/common-types.js +33 -0
- package/bpk-component-button/src/common-types.js +4 -25
- package/bpk-component-button/src/commonButtonTests.js +75 -57
- package/bpk-component-button/src/themeAttributes.js +7 -73
- package/bpk-component-button/themeAttributes.js +1 -14
- package/bpk-component-calendar/index.js +31 -0
- package/bpk-component-calendar/src/BpkCalendarContainer.js +271 -0
- package/bpk-component-calendar/src/{BpkCalendarDate.tsx → BpkCalendarDate.js} +43 -102
- package/bpk-component-calendar/src/BpkCalendarGrid.js +136 -0
- package/bpk-component-calendar/src/BpkCalendarGrid.module.css +1 -1
- package/bpk-component-calendar/src/BpkCalendarGridHeader.js +69 -0
- package/bpk-component-calendar/src/BpkCalendarGridTransition.js +159 -0
- package/bpk-component-calendar/src/BpkCalendarNav.js +155 -0
- package/bpk-component-calendar/src/Week.js +324 -0
- package/bpk-component-calendar/src/composeCalendar.js +125 -0
- package/bpk-component-calendar/src/custom-proptypes-legacy.js +18 -38
- package/{bpk-component-input/src/themeAttributes.ts → bpk-component-calendar/src/custom-proptypes.js} +4 -1
- package/bpk-component-calendar/src/{date-utils.ts → date-utils.js} +33 -89
- package/bpk-component-calendar/src/themeAttributes.js +19 -0
- package/bpk-component-calendar/src/{utils.ts → utils.js} +7 -20
- package/bpk-component-calendar/test-utils.js +239 -0
- package/bpk-component-card/{index.ts → index.js} +4 -6
- package/bpk-component-card/src/{BpkCard.tsx → BpkCard.js} +32 -51
- package/bpk-component-card/src/{BpkCardWrapper.tsx → BpkCardWrapper.js} +21 -31
- package/bpk-component-card/src/BpkCardWrapper.module.css +1 -1
- package/bpk-component-card/src/BpkDividedCard.js +58 -0
- package/bpk-component-checkbox/index.js +3 -8
- package/bpk-component-checkbox/src/BpkCheckbox.js +38 -79
- package/bpk-component-checkbox/src/themeAttributes.js +1 -5
- package/bpk-component-chip/index.js +25 -0
- package/bpk-component-chip/src/{BpkDismissibleChip.tsx → BpkDismissibleChip.js} +22 -28
- package/bpk-component-chip/src/{BpkDropdownChip.tsx → BpkDropdownChip.js} +13 -18
- package/bpk-component-chip/src/BpkSelectableChip.js +59 -0
- package/bpk-component-chip/src/{commonTypes.ts → commonTypes.js} +5 -18
- package/bpk-component-chip/src/themeAttributes.js +19 -0
- package/bpk-component-close-button/index.js +2 -7
- package/bpk-component-close-button/src/BpkCloseButton.js +28 -40
- package/bpk-component-code/index.js +3 -7
- package/bpk-component-code/src/BpkCode.js +20 -30
- package/bpk-component-code/src/BpkCodeBlock.js +23 -33
- package/bpk-component-content-cards/index.js +2 -3
- package/bpk-component-content-cards/src/BpkContentCard.js +34 -60
- package/bpk-component-content-cards/src/BpkContentCards.js +28 -44
- package/bpk-component-datatable/index.js +3 -4
- package/bpk-component-datatable/src/BpkDataTable.js +102 -155
- package/bpk-component-datatable/src/BpkDataTableColumn.js +11 -18
- package/bpk-component-datatable/src/BpkDataTableHeader.js +49 -88
- package/bpk-component-datatable/src/common-types.js +0 -72
- package/bpk-component-datatable/src/hasChildrenOfType.js +17 -41
- package/bpk-component-datatable/src/sort-types.js +3 -16
- package/bpk-component-datatable/src/utils.js +81 -65
- package/bpk-component-datepicker/{index.ts → index.js} +4 -6
- package/bpk-component-datepicker/src/BpkDatepicker.js +267 -0
- package/bpk-component-datepicker/src/{themeAttributes.ts → themeAttributes.js} +4 -11
- package/bpk-component-description-list/index.js +4 -5
- package/bpk-component-description-list/src/BpkDescriptionDetails.js +2 -3
- package/bpk-component-description-list/src/BpkDescriptionList.js +2 -3
- package/bpk-component-description-list/src/BpkDescriptionTerm.js +2 -3
- package/bpk-component-description-list/src/ComponentFactory.js +16 -21
- package/{bpk-component-banner-alert/src/themeAttributes.ts → bpk-component-dialog/index.js} +4 -6
- package/bpk-component-dialog/src/BpkDialog.js +63 -0
- package/bpk-component-dialog/src/BpkDialogInner.js +61 -0
- package/{bpk-component-aria-live/src/BpkAriaLive.module.scss → bpk-component-dialog/src/common-types.js} +5 -7
- package/bpk-component-drawer/index.js +3 -8
- package/bpk-component-drawer/src/BpkDrawer.js +39 -56
- package/bpk-component-drawer/src/BpkDrawerContent.js +58 -95
- package/bpk-component-drawer/src/themeAttributes.js +2 -7
- package/bpk-component-fieldset/index.js +3 -13
- package/bpk-component-fieldset/src/BpkFieldset.js +59 -105
- package/bpk-component-fieldset/src/themeAttributes.js +1 -1
- package/bpk-component-flare/index.js +3 -8
- package/bpk-component-flare/src/BpkContentBubble.js +30 -46
- package/bpk-component-flare/src/BpkFlareBar.js +29 -37
- package/bpk-component-flare/src/__generated__/js/corner-radius.js +8 -1
- package/bpk-component-flare/src/__generated__/js/pointer.js +8 -1
- package/bpk-component-floating-notification/index.js +2 -9
- package/bpk-component-floating-notification/src/BpkFloatingNotification.js +50 -78
- package/bpk-component-form-validation/index.js +3 -4
- package/bpk-component-form-validation/src/BpkFormValidation.js +37 -50
- package/bpk-component-form-validation/src/themeAttributes.js +1 -1
- package/{bpk-component-barchart/src/BpkBarchart.module.scss → bpk-component-graphic-promotion/index.js} +4 -4
- package/bpk-component-graphic-promotion/src/BpkGraphicPromo.js +144 -0
- package/bpk-component-grid-toggle/index.js +2 -3
- package/bpk-component-grid-toggle/src/BpkGridToggle.js +26 -45
- package/bpk-component-horizontal-nav/index.js +3 -15
- package/bpk-component-horizontal-nav/src/BpkHorizontalNav.js +39 -96
- package/bpk-component-horizontal-nav/src/BpkHorizontalNavItem.js +39 -78
- package/bpk-component-icon/{all.tsx → all.js} +5 -9
- package/bpk-component-icon/{index.tsx → index.js} +8 -21
- package/bpk-component-icon/lg/accessibility.js +14 -4
- package/bpk-component-icon/lg/account--add.js +14 -4
- package/bpk-component-icon/lg/account--female.js +14 -4
- package/bpk-component-icon/lg/account--id-card.js +14 -4
- package/bpk-component-icon/lg/account--name.js +14 -4
- package/bpk-component-icon/lg/account--permit.js +14 -4
- package/bpk-component-icon/lg/account-circle.js +14 -4
- package/bpk-component-icon/lg/account.js +14 -4
- package/bpk-component-icon/lg/add-circle.js +14 -4
- package/bpk-component-icon/lg/adult.js +14 -4
- package/bpk-component-icon/lg/ai.js +15 -4
- package/bpk-component-icon/lg/aircon.js +14 -4
- package/bpk-component-icon/lg/aircraft.js +17 -4
- package/bpk-component-icon/lg/airline--multiple.js +14 -4
- package/bpk-component-icon/lg/airline.js +14 -4
- package/bpk-component-icon/lg/airports.js +14 -4
- package/bpk-component-icon/lg/alert--active.js +14 -4
- package/bpk-component-icon/lg/alert--add.js +14 -4
- package/bpk-component-icon/lg/alert--expired.js +14 -4
- package/bpk-component-icon/lg/alert--remove.js +14 -4
- package/bpk-component-icon/lg/arrow-down.js +14 -4
- package/bpk-component-icon/lg/arrow-left.js +14 -4
- package/bpk-component-icon/lg/arrow-right.js +14 -4
- package/bpk-component-icon/lg/arrow-up.js +14 -4
- package/bpk-component-icon/lg/award.js +14 -4
- package/bpk-component-icon/lg/baby-carriage.js +14 -4
- package/bpk-component-icon/lg/baggage--add.js +14 -4
- package/bpk-component-icon/lg/baggage--remove.js +14 -4
- package/bpk-component-icon/lg/baggage-cabin-add.js +14 -4
- package/bpk-component-icon/lg/baggage-cabin-not-included.js +14 -4
- package/bpk-component-icon/lg/baggage-cabin.js +14 -4
- package/bpk-component-icon/lg/baggage-checked-add.js +14 -4
- package/bpk-component-icon/lg/baggage-checked-not-included.js +14 -4
- package/bpk-component-icon/lg/baggage-checked.js +14 -4
- package/bpk-component-icon/lg/baggage-cross.js +14 -4
- package/bpk-component-icon/lg/baggage-generic.js +14 -4
- package/bpk-component-icon/lg/baggage-tick.js +14 -4
- package/bpk-component-icon/lg/baggage.js +14 -4
- package/bpk-component-icon/lg/bar.js +14 -4
- package/bpk-component-icon/lg/beach.js +17 -4
- package/bpk-component-icon/lg/beer.js +14 -4
- package/bpk-component-icon/lg/breakfast-cross.js +14 -4
- package/bpk-component-icon/lg/breakfast-tick.js +14 -4
- package/bpk-component-icon/lg/bus.js +14 -4
- package/bpk-component-icon/lg/business.js +14 -4
- package/bpk-component-icon/lg/cafe.js +14 -4
- package/bpk-component-icon/lg/calendar.js +14 -4
- package/bpk-component-icon/lg/call-back.js +17 -4
- package/bpk-component-icon/lg/camera.js +14 -4
- package/bpk-component-icon/lg/camper-van.js +17 -4
- package/bpk-component-icon/lg/car-door.js +14 -4
- package/bpk-component-icon/lg/car-wash.js +17 -4
- package/bpk-component-icon/lg/cars-flexible.js +14 -4
- package/bpk-component-icon/lg/cars.js +17 -4
- package/bpk-component-icon/lg/center-location.js +14 -4
- package/bpk-component-icon/lg/chart.js +14 -4
- package/bpk-component-icon/lg/chauffeur.js +14 -4
- package/bpk-component-icon/lg/chevron-down.js +14 -4
- package/bpk-component-icon/lg/chevron-left.js +14 -4
- package/bpk-component-icon/lg/chevron-right.js +14 -4
- package/bpk-component-icon/lg/chevron-up.js +14 -4
- package/bpk-component-icon/lg/child-seat.js +14 -4
- package/bpk-component-icon/lg/child.js +14 -4
- package/bpk-component-icon/lg/city-center.js +14 -4
- package/bpk-component-icon/lg/city.js +14 -4
- package/bpk-component-icon/lg/clean-policy.js +14 -4
- package/bpk-component-icon/lg/clean.js +19 -4
- package/bpk-component-icon/lg/cleaning-medical.js +14 -4
- package/bpk-component-icon/lg/cloakroom.js +19 -4
- package/bpk-component-icon/lg/close-circle.js +14 -4
- package/bpk-component-icon/lg/close.js +14 -4
- package/bpk-component-icon/lg/collapse.js +14 -4
- package/bpk-component-icon/lg/content--copy.js +17 -4
- package/bpk-component-icon/lg/content--event.js +14 -4
- package/bpk-component-icon/lg/content--guides.js +14 -4
- package/bpk-component-icon/lg/currency.js +14 -4
- package/bpk-component-icon/lg/data.js +17 -4
- package/bpk-component-icon/lg/deals.js +14 -4
- package/bpk-component-icon/lg/depart.js +17 -4
- package/bpk-component-icon/lg/device-mid.js +14 -4
- package/bpk-component-icon/lg/device-wide.js +14 -4
- package/bpk-component-icon/lg/direct.js +14 -4
- package/bpk-component-icon/lg/document-csv.js +14 -4
- package/bpk-component-icon/lg/document-pdf.js +14 -4
- package/bpk-component-icon/lg/download.js +17 -4
- package/bpk-component-icon/lg/duration.js +14 -4
- package/bpk-component-icon/lg/eco-leaf.js +14 -4
- package/bpk-component-icon/lg/edit.js +14 -4
- package/bpk-component-icon/lg/education.js +17 -4
- package/bpk-component-icon/lg/electric.js +14 -4
- package/bpk-component-icon/lg/end-call.js +14 -4
- package/bpk-component-icon/lg/estimated.js +14 -4
- package/bpk-component-icon/lg/exclamation-circle.js +14 -4
- package/bpk-component-icon/lg/exclamation.js +14 -4
- package/bpk-component-icon/lg/expand.js +14 -4
- package/bpk-component-icon/lg/explore.js +14 -4
- package/bpk-component-icon/lg/face--blank.js +14 -4
- package/bpk-component-icon/lg/face--happy.js +14 -4
- package/bpk-component-icon/lg/face--sad.js +14 -4
- package/bpk-component-icon/lg/face-id.js +14 -4
- package/bpk-component-icon/lg/face-mask.js +14 -4
- package/bpk-component-icon/lg/family.js +14 -4
- package/bpk-component-icon/lg/fast-track.js +17 -4
- package/bpk-component-icon/lg/fast-train.js +17 -4
- package/bpk-component-icon/lg/filter.js +15 -4
- package/bpk-component-icon/lg/fingerprint.js +14 -4
- package/bpk-component-icon/lg/flag.js +14 -4
- package/bpk-component-icon/lg/flask.js +14 -4
- package/bpk-component-icon/lg/flight-flexible.js +14 -4
- package/bpk-component-icon/lg/flight-landing.js +19 -4
- package/bpk-component-icon/lg/flight-takeoff.js +17 -4
- package/bpk-component-icon/lg/flight.js +17 -4
- package/bpk-component-icon/lg/food.js +14 -4
- package/bpk-component-icon/lg/gears-automatic-circle.js +14 -4
- package/bpk-component-icon/lg/gears-automatic.js +14 -4
- package/bpk-component-icon/lg/gears-manual-circle.js +14 -4
- package/bpk-component-icon/lg/gears-manual.js +14 -4
- package/bpk-component-icon/lg/globe.js +14 -4
- package/bpk-component-icon/lg/grid-layout.js +14 -4
- package/bpk-component-icon/lg/headset.js +14 -4
- package/bpk-component-icon/lg/health-fitness.js +14 -4
- package/bpk-component-icon/lg/heart--outline.js +14 -4
- package/bpk-component-icon/lg/heart.js +14 -4
- package/bpk-component-icon/lg/help-circle.js +14 -4
- package/bpk-component-icon/lg/help.js +14 -4
- package/bpk-component-icon/lg/hide.js +14 -4
- package/bpk-component-icon/lg/hotel-flexible.js +14 -4
- package/bpk-component-icon/lg/hotels--disabled-facilities.js +14 -4
- package/bpk-component-icon/lg/hotels--jacuzzi.js +14 -4
- package/bpk-component-icon/lg/hotels--pets-allowed.js +14 -4
- package/bpk-component-icon/lg/hotels--smoking.js +14 -4
- package/bpk-component-icon/lg/hotels.js +14 -4
- package/bpk-component-icon/lg/infant.js +14 -4
- package/bpk-component-icon/lg/information--language-alert.js +14 -4
- package/bpk-component-icon/lg/information--language-question.js +14 -4
- package/bpk-component-icon/lg/information--language.js +14 -4
- package/bpk-component-icon/lg/information-circle.js +14 -4
- package/bpk-component-icon/lg/information.js +14 -4
- package/bpk-component-icon/lg/insurance.js +14 -4
- package/bpk-component-icon/lg/key.js +14 -4
- package/bpk-component-icon/lg/keypad.js +14 -4
- package/bpk-component-icon/lg/landmark.js +14 -4
- package/bpk-component-icon/lg/language.js +14 -4
- package/bpk-component-icon/lg/legroom--extra.js +17 -4
- package/bpk-component-icon/lg/legroom--normal.js +17 -4
- package/bpk-component-icon/lg/legroom--reduced.js +17 -4
- package/bpk-component-icon/lg/leisure.js +14 -4
- package/bpk-component-icon/lg/lightning.js +14 -4
- package/bpk-component-icon/lg/list.js +14 -4
- package/bpk-component-icon/lg/location.js +14 -4
- package/bpk-component-icon/lg/lock.js +14 -4
- package/bpk-component-icon/lg/logout.js +17 -4
- package/bpk-component-icon/lg/long-arrow-down.js +14 -4
- package/bpk-component-icon/lg/long-arrow-left.js +14 -4
- package/bpk-component-icon/lg/long-arrow-right.js +14 -4
- package/bpk-component-icon/lg/long-arrow-up.js +14 -4
- package/bpk-component-icon/lg/lounge.js +17 -4
- package/bpk-component-icon/lg/luggageall.js +14 -4
- package/bpk-component-icon/lg/mail.js +17 -4
- package/bpk-component-icon/lg/map.js +14 -4
- package/bpk-component-icon/lg/meal.js +14 -4
- package/bpk-component-icon/lg/media.js +14 -4
- package/bpk-component-icon/lg/menu--horizontal.js +14 -4
- package/bpk-component-icon/lg/menu--vertical.js +14 -4
- package/bpk-component-icon/lg/menu.js +14 -4
- package/bpk-component-icon/lg/mileage.js +17 -4
- package/bpk-component-icon/lg/minus.js +14 -4
- package/bpk-component-icon/lg/mobile.js +14 -4
- package/bpk-component-icon/lg/money.js +14 -4
- package/bpk-component-icon/lg/multiple-bookings.js +14 -4
- package/bpk-component-icon/lg/music.js +14 -4
- package/bpk-component-icon/lg/mute.js +14 -4
- package/bpk-component-icon/lg/native-android--back.js +14 -4
- package/bpk-component-icon/lg/native-android--close.js +14 -4
- package/bpk-component-icon/lg/native-android--forward.js +14 -4
- package/bpk-component-icon/lg/native-ios-close.js +14 -4
- package/bpk-component-icon/lg/navigation.js +14 -4
- package/bpk-component-icon/lg/new-window.js +17 -4
- package/bpk-component-icon/lg/news.js +14 -4
- package/bpk-component-icon/lg/night.js +14 -4
- package/bpk-component-icon/lg/not-allowed.js +14 -4
- package/bpk-component-icon/lg/onsen.js +14 -4
- package/bpk-component-icon/lg/origin.js +14 -4
- package/bpk-component-icon/lg/paid.js +14 -4
- package/bpk-component-icon/lg/paperclip.js +14 -4
- package/bpk-component-icon/lg/parking.js +14 -4
- package/bpk-component-icon/lg/passport.js +14 -4
- package/bpk-component-icon/lg/pause.js +14 -4
- package/bpk-component-icon/lg/payment-card.js +14 -4
- package/bpk-component-icon/lg/petrol.js +14 -4
- package/bpk-component-icon/lg/phone-call.js +14 -4
- package/bpk-component-icon/lg/picture.js +14 -4
- package/bpk-component-icon/lg/pin.js +14 -4
- package/bpk-component-icon/lg/plane-seat.js +17 -4
- package/bpk-component-icon/lg/play.js +14 -4
- package/bpk-component-icon/lg/plus.js +14 -4
- package/bpk-component-icon/lg/policy.js +14 -4
- package/bpk-component-icon/lg/powerplug.js +14 -4
- package/bpk-component-icon/lg/ppe.js +14 -4
- package/bpk-component-icon/lg/price-alerts.js +14 -4
- package/bpk-component-icon/lg/price-tag.js +14 -4
- package/bpk-component-icon/lg/print.js +14 -4
- package/bpk-component-icon/lg/recent-searches.js +14 -4
- package/bpk-component-icon/lg/redo.js +14 -4
- package/bpk-component-icon/lg/refresh.js +14 -4
- package/bpk-component-icon/lg/return.js +17 -4
- package/bpk-component-icon/lg/room.js +14 -4
- package/bpk-component-icon/lg/scales.js +17 -4
- package/bpk-component-icon/lg/search.js +14 -4
- package/bpk-component-icon/lg/self-service.js +14 -4
- package/bpk-component-icon/lg/send-message.js +14 -4
- package/bpk-component-icon/lg/services.js +14 -4
- package/bpk-component-icon/lg/settings.js +14 -4
- package/bpk-component-icon/lg/share--android.js +14 -4
- package/bpk-component-icon/lg/share--ios.js +17 -4
- package/bpk-component-icon/lg/share.js +14 -4
- package/bpk-component-icon/lg/single-booking.js +14 -4
- package/bpk-component-icon/lg/social-distancing.js +17 -4
- package/bpk-component-icon/lg/social-like.js +14 -4
- package/bpk-component-icon/lg/sort-down.js +14 -4
- package/bpk-component-icon/lg/sort-up.js +14 -4
- package/bpk-component-icon/lg/sort.js +14 -4
- package/bpk-component-icon/lg/speaker.js +17 -4
- package/bpk-component-icon/lg/star-half.js +14 -4
- package/bpk-component-icon/lg/star-outline.js +14 -4
- package/bpk-component-icon/lg/star.js +14 -4
- package/bpk-component-icon/lg/stops.js +14 -4
- package/bpk-component-icon/lg/swap--horizontal.js +14 -4
- package/bpk-component-icon/lg/swap--vertical.js +14 -4
- package/bpk-component-icon/lg/swap.js +14 -4
- package/bpk-component-icon/lg/taxi.js +17 -4
- package/bpk-component-icon/lg/thumbs-down.js +14 -4
- package/bpk-component-icon/lg/thumbs-up.js +14 -4
- package/bpk-component-icon/lg/tick-circle.js +14 -4
- package/bpk-component-icon/lg/tick.js +14 -4
- package/bpk-component-icon/lg/ticket-flexible.js +14 -4
- package/bpk-component-icon/lg/ticket.js +14 -4
- package/bpk-component-icon/lg/time.js +14 -4
- package/bpk-component-icon/lg/toilets.js +14 -4
- package/bpk-component-icon/lg/train.js +14 -4
- package/bpk-component-icon/lg/transmission-automatic.js +14 -4
- package/bpk-component-icon/lg/transmission-manual.js +14 -4
- package/bpk-component-icon/lg/trash.js +14 -4
- package/bpk-component-icon/lg/trend--down.js +14 -4
- package/bpk-component-icon/lg/trend--steady.js +14 -4
- package/bpk-component-icon/lg/trend--will-rise.js +14 -4
- package/bpk-component-icon/lg/trend.js +14 -4
- package/bpk-component-icon/lg/trips.js +14 -4
- package/bpk-component-icon/lg/undo.js +14 -4
- package/bpk-component-icon/lg/unlock.js +14 -4
- package/bpk-component-icon/lg/unmute.js +17 -4
- package/bpk-component-icon/lg/upgrade.js +14 -4
- package/bpk-component-icon/lg/upload.js +15 -4
- package/bpk-component-icon/lg/use-location.js +14 -4
- package/bpk-component-icon/lg/view.js +14 -4
- package/bpk-component-icon/lg/virus.js +14 -4
- package/bpk-component-icon/lg/wallet.js +17 -4
- package/bpk-component-icon/lg/weather--clear.js +14 -4
- package/bpk-component-icon/lg/weather--cloudy.js +17 -4
- package/bpk-component-icon/lg/weather--fog.js +14 -4
- package/bpk-component-icon/lg/weather--partly-cloudy.js +17 -4
- package/bpk-component-icon/lg/weather--rain.js +19 -4
- package/bpk-component-icon/lg/weather--snow.js +14 -4
- package/bpk-component-icon/lg/weather--thunderstorm.js +19 -4
- package/bpk-component-icon/lg/weather--tornado.js +14 -4
- package/bpk-component-icon/lg/weather--wind.js +14 -4
- package/bpk-component-icon/lg/weather.js +14 -4
- package/bpk-component-icon/lg/wifi.js +14 -4
- package/bpk-component-icon/lg/window--reduce.js +17 -4
- package/bpk-component-icon/lg/window.js +14 -4
- package/bpk-component-icon/lg/world--amer.js +14 -4
- package/bpk-component-icon/lg/world--apac.js +14 -4
- package/bpk-component-icon/lg/world--emea.js +17 -4
- package/bpk-component-icon/sm/accessibility.js +15 -4
- package/bpk-component-icon/sm/account--add.js +15 -4
- package/bpk-component-icon/sm/account--female.js +15 -4
- package/bpk-component-icon/sm/account--id-card.js +15 -4
- package/bpk-component-icon/sm/account--name.js +15 -4
- package/bpk-component-icon/sm/account--permit.js +15 -4
- package/bpk-component-icon/sm/account-circle.js +15 -4
- package/bpk-component-icon/sm/account.js +15 -4
- package/bpk-component-icon/sm/add-circle.js +15 -4
- package/bpk-component-icon/sm/adult.js +15 -4
- package/bpk-component-icon/sm/ai.js +16 -4
- package/bpk-component-icon/sm/aircon.js +15 -4
- package/bpk-component-icon/sm/aircraft.js +18 -4
- package/bpk-component-icon/sm/airline--multiple.js +15 -4
- package/bpk-component-icon/sm/airline.js +15 -4
- package/bpk-component-icon/sm/airports.js +15 -4
- package/bpk-component-icon/sm/alert--active.js +15 -4
- package/bpk-component-icon/sm/alert--add.js +15 -4
- package/bpk-component-icon/sm/alert--expired.js +15 -4
- package/bpk-component-icon/sm/alert--remove.js +15 -4
- package/bpk-component-icon/sm/arrow-down.js +15 -4
- package/bpk-component-icon/sm/arrow-left.js +15 -4
- package/bpk-component-icon/sm/arrow-right.js +15 -4
- package/bpk-component-icon/sm/arrow-up.js +15 -4
- package/bpk-component-icon/sm/award.js +15 -4
- package/bpk-component-icon/sm/baby-carriage.js +15 -4
- package/bpk-component-icon/sm/baggage--add.js +15 -4
- package/bpk-component-icon/sm/baggage--remove.js +15 -4
- package/bpk-component-icon/sm/baggage-cabin-add.js +15 -4
- package/bpk-component-icon/sm/baggage-cabin-not-included.js +18 -4
- package/bpk-component-icon/sm/baggage-cabin.js +15 -4
- package/bpk-component-icon/sm/baggage-checked-add.js +15 -4
- package/bpk-component-icon/sm/baggage-checked-not-included.js +18 -4
- package/bpk-component-icon/sm/baggage-checked.js +15 -4
- package/bpk-component-icon/sm/baggage-cross.js +15 -4
- package/bpk-component-icon/sm/baggage-generic.js +18 -4
- package/bpk-component-icon/sm/baggage-tick.js +15 -4
- package/bpk-component-icon/sm/baggage.js +15 -4
- package/bpk-component-icon/sm/bar.js +15 -4
- package/bpk-component-icon/sm/beach.js +18 -4
- package/bpk-component-icon/sm/beer.js +15 -4
- package/bpk-component-icon/sm/breakfast-cross.js +15 -4
- package/bpk-component-icon/sm/breakfast-tick.js +15 -4
- package/bpk-component-icon/sm/bus.js +18 -4
- package/bpk-component-icon/sm/business.js +15 -4
- package/bpk-component-icon/sm/cafe.js +15 -4
- package/bpk-component-icon/sm/calendar.js +15 -4
- package/bpk-component-icon/sm/call-back.js +18 -4
- package/bpk-component-icon/sm/camera.js +15 -4
- package/bpk-component-icon/sm/camper-van.js +18 -4
- package/bpk-component-icon/sm/car-door.js +15 -4
- package/bpk-component-icon/sm/car-wash.js +18 -4
- package/bpk-component-icon/sm/cars-flexible.js +15 -4
- package/bpk-component-icon/sm/cars.js +18 -4
- package/bpk-component-icon/sm/center-location.js +15 -4
- package/bpk-component-icon/sm/chart.js +15 -4
- package/bpk-component-icon/sm/chauffeur.js +18 -4
- package/bpk-component-icon/sm/chevron-down.js +15 -4
- package/bpk-component-icon/sm/chevron-left.js +15 -4
- package/bpk-component-icon/sm/chevron-right.js +15 -4
- package/bpk-component-icon/sm/chevron-up.js +15 -4
- package/bpk-component-icon/sm/child-seat.js +15 -4
- package/bpk-component-icon/sm/child.js +15 -4
- package/bpk-component-icon/sm/city-center.js +15 -4
- package/bpk-component-icon/sm/city.js +15 -4
- package/bpk-component-icon/sm/clean-policy.js +15 -4
- package/bpk-component-icon/sm/clean.js +18 -4
- package/bpk-component-icon/sm/cleaning-medical.js +15 -4
- package/bpk-component-icon/sm/cloakroom.js +15 -4
- package/bpk-component-icon/sm/close-circle.js +15 -4
- package/bpk-component-icon/sm/close.js +15 -4
- package/bpk-component-icon/sm/collapse.js +15 -4
- package/bpk-component-icon/sm/content--copy.js +18 -4
- package/bpk-component-icon/sm/content--event.js +15 -4
- package/bpk-component-icon/sm/content--guides.js +15 -4
- package/bpk-component-icon/sm/currency.js +15 -4
- package/bpk-component-icon/sm/data.js +18 -4
- package/bpk-component-icon/sm/deals.js +15 -4
- package/bpk-component-icon/sm/depart.js +20 -4
- package/bpk-component-icon/sm/device-mid.js +15 -4
- package/bpk-component-icon/sm/device-wide.js +15 -4
- package/bpk-component-icon/sm/direct.js +18 -4
- package/bpk-component-icon/sm/document-csv.js +15 -4
- package/bpk-component-icon/sm/document-pdf.js +15 -4
- package/bpk-component-icon/sm/download.js +18 -4
- package/bpk-component-icon/sm/duration.js +15 -4
- package/bpk-component-icon/sm/eco-leaf.js +15 -4
- package/bpk-component-icon/sm/edit.js +15 -4
- package/bpk-component-icon/sm/education.js +18 -4
- package/bpk-component-icon/sm/electric.js +15 -4
- package/bpk-component-icon/sm/end-call.js +15 -4
- package/bpk-component-icon/sm/estimated.js +15 -4
- package/bpk-component-icon/sm/exclamation-circle.js +15 -4
- package/bpk-component-icon/sm/exclamation.js +15 -4
- package/bpk-component-icon/sm/expand.js +15 -4
- package/bpk-component-icon/sm/explore.js +15 -4
- package/bpk-component-icon/sm/face--blank.js +15 -4
- package/bpk-component-icon/sm/face--happy.js +15 -4
- package/bpk-component-icon/sm/face--sad.js +15 -4
- package/bpk-component-icon/sm/face-id.js +15 -4
- package/bpk-component-icon/sm/face-mask.js +15 -4
- package/bpk-component-icon/sm/family.js +15 -4
- package/bpk-component-icon/sm/fast-track.js +18 -4
- package/bpk-component-icon/sm/fast-train.js +18 -4
- package/bpk-component-icon/sm/filter.js +16 -4
- package/bpk-component-icon/sm/fingerprint.js +15 -4
- package/bpk-component-icon/sm/flag.js +15 -4
- package/bpk-component-icon/sm/flask.js +15 -4
- package/bpk-component-icon/sm/flight-flexible.js +15 -4
- package/bpk-component-icon/sm/flight-landing.js +20 -4
- package/bpk-component-icon/sm/flight-takeoff.js +18 -4
- package/bpk-component-icon/sm/flight.js +18 -4
- package/bpk-component-icon/sm/food.js +15 -4
- package/bpk-component-icon/sm/gears-automatic-circle.js +15 -4
- package/bpk-component-icon/sm/gears-automatic.js +15 -4
- package/bpk-component-icon/sm/gears-manual-circle.js +15 -4
- package/bpk-component-icon/sm/gears-manual.js +15 -4
- package/bpk-component-icon/sm/globe.js +15 -4
- package/bpk-component-icon/sm/grid-layout.js +15 -4
- package/bpk-component-icon/sm/headset.js +15 -4
- package/bpk-component-icon/sm/health-fitness.js +15 -4
- package/bpk-component-icon/sm/heart--outline.js +15 -4
- package/bpk-component-icon/sm/heart.js +15 -4
- package/bpk-component-icon/sm/help-circle.js +15 -4
- package/bpk-component-icon/sm/help.js +15 -4
- package/bpk-component-icon/sm/hide.js +15 -4
- package/bpk-component-icon/sm/hotel-flexible.js +15 -4
- package/bpk-component-icon/sm/hotels--disabled-facilities.js +15 -4
- package/bpk-component-icon/sm/hotels--jacuzzi.js +18 -4
- package/bpk-component-icon/sm/hotels--pets-allowed.js +15 -4
- package/bpk-component-icon/sm/hotels--smoking.js +15 -4
- package/bpk-component-icon/sm/hotels.js +15 -4
- package/bpk-component-icon/sm/infant.js +18 -4
- package/bpk-component-icon/sm/information--language-alert.js +15 -4
- package/bpk-component-icon/sm/information--language-question.js +15 -4
- package/bpk-component-icon/sm/information--language.js +15 -4
- package/bpk-component-icon/sm/information-circle.js +15 -4
- package/bpk-component-icon/sm/information.js +15 -4
- package/bpk-component-icon/sm/insurance.js +15 -4
- package/bpk-component-icon/sm/key.js +15 -4
- package/bpk-component-icon/sm/keypad.js +15 -4
- package/bpk-component-icon/sm/landmark.js +15 -4
- package/bpk-component-icon/sm/language.js +15 -4
- package/bpk-component-icon/sm/legroom--extra.js +18 -4
- package/bpk-component-icon/sm/legroom--normal.js +18 -4
- package/bpk-component-icon/sm/legroom--reduced.js +18 -4
- package/bpk-component-icon/sm/leisure.js +15 -4
- package/bpk-component-icon/sm/lightning.js +15 -4
- package/bpk-component-icon/sm/list.js +15 -4
- package/bpk-component-icon/sm/location.js +15 -4
- package/bpk-component-icon/sm/lock.js +15 -4
- package/bpk-component-icon/sm/logout.js +18 -4
- package/bpk-component-icon/sm/long-arrow-down.js +16 -4
- package/bpk-component-icon/sm/long-arrow-left.js +16 -4
- package/bpk-component-icon/sm/long-arrow-right.js +16 -4
- package/bpk-component-icon/sm/long-arrow-up.js +16 -4
- package/bpk-component-icon/sm/lounge.js +15 -4
- package/bpk-component-icon/sm/luggageall.js +15 -4
- package/bpk-component-icon/sm/mail.js +18 -4
- package/bpk-component-icon/sm/map.js +15 -4
- package/bpk-component-icon/sm/meal.js +15 -4
- package/bpk-component-icon/sm/media.js +15 -4
- package/bpk-component-icon/sm/menu--horizontal.js +15 -4
- package/bpk-component-icon/sm/menu--vertical.js +15 -4
- package/bpk-component-icon/sm/menu.js +15 -4
- package/bpk-component-icon/sm/mileage.js +18 -4
- package/bpk-component-icon/sm/minus.js +15 -4
- package/bpk-component-icon/sm/mobile.js +15 -4
- package/bpk-component-icon/sm/money.js +15 -4
- package/bpk-component-icon/sm/multiple-bookings.js +15 -4
- package/bpk-component-icon/sm/music.js +15 -4
- package/bpk-component-icon/sm/mute.js +15 -4
- package/bpk-component-icon/sm/native-android--back.js +15 -4
- package/bpk-component-icon/sm/native-android--close.js +15 -4
- package/bpk-component-icon/sm/native-android--forward.js +15 -4
- package/bpk-component-icon/sm/native-ios-close.js +15 -4
- package/bpk-component-icon/sm/navigation.js +15 -4
- package/bpk-component-icon/sm/new-window.js +22 -4
- package/bpk-component-icon/sm/news.js +15 -4
- package/bpk-component-icon/sm/night.js +15 -4
- package/bpk-component-icon/sm/not-allowed.js +15 -4
- package/bpk-component-icon/sm/onsen.js +18 -4
- package/bpk-component-icon/sm/origin.js +15 -4
- package/bpk-component-icon/sm/paid.js +15 -4
- package/bpk-component-icon/sm/paperclip.js +15 -4
- package/bpk-component-icon/sm/parking.js +15 -4
- package/bpk-component-icon/sm/passport.js +15 -4
- package/bpk-component-icon/sm/pause.js +15 -4
- package/bpk-component-icon/sm/payment-card.js +15 -4
- package/bpk-component-icon/sm/petrol.js +15 -4
- package/bpk-component-icon/sm/phone-call.js +15 -4
- package/bpk-component-icon/sm/picture.js +15 -4
- package/bpk-component-icon/sm/pin.js +15 -4
- package/bpk-component-icon/sm/plane-seat.js +18 -4
- package/bpk-component-icon/sm/play.js +15 -4
- package/bpk-component-icon/sm/plus.js +15 -4
- package/bpk-component-icon/sm/policy.js +15 -4
- package/bpk-component-icon/sm/powerplug.js +15 -4
- package/bpk-component-icon/sm/ppe.js +15 -4
- package/bpk-component-icon/sm/price-alerts.js +15 -4
- package/bpk-component-icon/sm/price-tag.js +15 -4
- package/bpk-component-icon/sm/print.js +15 -4
- package/bpk-component-icon/sm/recent-searches.js +15 -4
- package/bpk-component-icon/sm/redo.js +15 -4
- package/bpk-component-icon/sm/refresh.js +15 -4
- package/bpk-component-icon/sm/return.js +20 -4
- package/bpk-component-icon/sm/room.js +15 -4
- package/bpk-component-icon/sm/scales.js +15 -4
- package/bpk-component-icon/sm/search.js +15 -4
- package/bpk-component-icon/sm/self-service.js +15 -4
- package/bpk-component-icon/sm/send-message.js +15 -4
- package/bpk-component-icon/sm/services.js +15 -4
- package/bpk-component-icon/sm/settings.js +15 -4
- package/bpk-component-icon/sm/share--android.js +15 -4
- package/bpk-component-icon/sm/share--ios.js +20 -4
- package/bpk-component-icon/sm/share.js +15 -4
- package/bpk-component-icon/sm/single-booking.js +15 -4
- package/bpk-component-icon/sm/social-distancing.js +18 -4
- package/bpk-component-icon/sm/social-like.js +15 -4
- package/bpk-component-icon/sm/sort-down.js +15 -4
- package/bpk-component-icon/sm/sort-up.js +15 -4
- package/bpk-component-icon/sm/sort.js +15 -4
- package/bpk-component-icon/sm/speaker.js +15 -4
- package/bpk-component-icon/sm/star-half.js +15 -4
- package/bpk-component-icon/sm/star-outline.js +15 -4
- package/bpk-component-icon/sm/star.js +15 -4
- package/bpk-component-icon/sm/stops.js +15 -4
- package/bpk-component-icon/sm/swap--horizontal.js +16 -4
- package/bpk-component-icon/sm/swap--vertical.js +15 -4
- package/bpk-component-icon/sm/swap.js +16 -4
- package/bpk-component-icon/sm/taxi.js +18 -4
- package/bpk-component-icon/sm/thumbs-down.js +15 -4
- package/bpk-component-icon/sm/thumbs-up.js +15 -4
- package/bpk-component-icon/sm/tick-circle.js +15 -4
- package/bpk-component-icon/sm/tick.js +15 -4
- package/bpk-component-icon/sm/ticket-flexible.js +15 -4
- package/bpk-component-icon/sm/ticket.js +15 -4
- package/bpk-component-icon/sm/time.js +15 -4
- package/bpk-component-icon/sm/toilets.js +15 -4
- package/bpk-component-icon/sm/train.js +15 -4
- package/bpk-component-icon/sm/transmission-automatic.js +15 -4
- package/bpk-component-icon/sm/transmission-manual.js +15 -4
- package/bpk-component-icon/sm/trash.js +15 -4
- package/bpk-component-icon/sm/trend--down.js +15 -4
- package/bpk-component-icon/sm/trend--steady.js +16 -4
- package/bpk-component-icon/sm/trend--will-rise.js +15 -4
- package/bpk-component-icon/sm/trend.js +15 -4
- package/bpk-component-icon/sm/trips.js +15 -4
- package/bpk-component-icon/sm/undo.js +15 -4
- package/bpk-component-icon/sm/unlock.js +15 -4
- package/bpk-component-icon/sm/unmute.js +18 -4
- package/bpk-component-icon/sm/upgrade.js +15 -4
- package/bpk-component-icon/sm/upload.js +16 -4
- package/bpk-component-icon/sm/use-location.js +15 -4
- package/bpk-component-icon/sm/view.js +15 -4
- package/bpk-component-icon/sm/virus.js +15 -4
- package/bpk-component-icon/sm/wallet.js +15 -4
- package/bpk-component-icon/sm/weather--clear.js +15 -4
- package/bpk-component-icon/sm/weather--cloudy.js +18 -4
- package/bpk-component-icon/sm/weather--fog.js +15 -4
- package/bpk-component-icon/sm/weather--partly-cloudy.js +15 -4
- package/bpk-component-icon/sm/weather--rain.js +18 -4
- package/bpk-component-icon/sm/weather--snow.js +15 -4
- package/bpk-component-icon/sm/weather--thunderstorm.js +20 -4
- package/bpk-component-icon/sm/weather--tornado.js +15 -4
- package/bpk-component-icon/sm/weather--wind.js +18 -4
- package/bpk-component-icon/sm/weather.js +15 -4
- package/bpk-component-icon/sm/wifi.js +15 -4
- package/bpk-component-icon/sm/window--reduce.js +18 -4
- package/bpk-component-icon/sm/window.js +15 -4
- package/bpk-component-icon/sm/world--amer.js +15 -4
- package/bpk-component-icon/sm/world--apac.js +15 -4
- package/bpk-component-icon/sm/world--emea.js +15 -4
- package/bpk-component-icon/src/classNameModifierHOCFactory.js +39 -0
- package/bpk-component-icon/src/withAlignment.js +40 -0
- package/bpk-component-icon/src/{withDescription.tsx → withDescription.js} +14 -22
- package/bpk-component-icon/src/{withRtlSupport.tsx → withRtlSupport.js} +4 -9
- package/bpk-component-image/index.js +25 -0
- package/bpk-component-image/src/BpkBackgroundImage.js +130 -0
- package/bpk-component-image/src/BpkImage.js +153 -0
- package/{bpk-component-button/src/BpkButtonSecondary.module.scss → bpk-component-image/src/BpkImageBorderRadiusStyles.js} +5 -5
- package/bpk-component-image/src/{withLazyLoading.tsx → withLazyLoading.js} +44 -87
- package/bpk-component-image/src/{withLoadingBehavior.tsx → withLoadingBehavior.js} +14 -41
- package/bpk-component-infinite-scroll/index.js +3 -13
- package/bpk-component-infinite-scroll/src/DataSource.js +15 -30
- package/bpk-component-infinite-scroll/src/intersection-observer.js +1 -1
- package/bpk-component-infinite-scroll/src/withInfiniteScroll.js +178 -240
- package/bpk-component-input/index.js +24 -0
- package/bpk-component-input/src/{BpkClearButton.tsx → BpkClearButton.js} +26 -32
- package/bpk-component-input/src/{BpkInput.tsx → BpkInput.js} +62 -85
- package/bpk-component-input/src/{common-types.ts → common-types.js} +13 -74
- package/{bpk-component-map/src/BpkMap.module.scss → bpk-component-input/src/themeAttributes.js} +1 -3
- package/bpk-component-input/src/{withOpenEvents.tsx → withOpenEvents.js} +37 -106
- package/bpk-component-label/index.js +2 -8
- package/bpk-component-label/src/BpkLabel.js +28 -45
- package/bpk-component-link/index.js +4 -11
- package/bpk-component-link/src/BpkButtonLink.js +24 -38
- package/bpk-component-link/src/BpkLink.js +21 -50
- package/bpk-component-link/src/themeAttributes.js +3 -19
- package/bpk-component-list/index.js +3 -8
- package/bpk-component-list/src/BpkList.js +26 -48
- package/bpk-component-list/src/BpkListItem.js +17 -32
- package/bpk-component-loading-button/index.js +2 -7
- package/bpk-component-loading-button/src/BpkLoadingButton.js +52 -107
- package/bpk-component-map/index.js +7 -28
- package/bpk-component-map/src/BpkBasicMapMarker.js +21 -32
- package/bpk-component-map/src/BpkIconMarker.js +34 -62
- package/bpk-component-map/src/BpkIconMarkerBackground.js +37 -49
- package/bpk-component-map/src/BpkMap.js +65 -130
- package/bpk-component-map/src/BpkOverlayView.js +21 -26
- package/bpk-component-map/src/BpkPriceMarker.js +34 -72
- package/bpk-component-map/src/DefaultLoadingElement.js +11 -16
- package/bpk-component-map/src/common-types.js +3 -13
- package/bpk-component-map/src/themeAttributes.js +4 -18
- package/bpk-component-map/src/withGoogleMapsScript.js +17 -35
- package/bpk-component-mobile-scroll-container/index.js +2 -7
- package/bpk-component-mobile-scroll-container/src/BpkMobileScrollContainer.js +52 -121
- package/bpk-component-modal/{index.ts → index.js} +5 -9
- package/bpk-component-modal/src/BpkModal.js +79 -0
- package/bpk-component-modal/src/BpkModalInner.js +112 -0
- package/bpk-component-modal/src/BpkModalV2/BpKModal.module.css +18 -0
- package/bpk-component-modal/src/BpkModalV2/BpkModal.js +145 -0
- package/bpk-component-modal/src/customPropTypes.js +6 -30
- package/bpk-component-modal/src/legacy-prop-types.js +11 -15
- package/bpk-component-modal/src/{themeAttributes.ts → themeAttributes.js} +2 -3
- package/bpk-component-navigation-bar/index.js +6 -26
- package/bpk-component-navigation-bar/src/BpkNavigationBar.js +28 -60
- package/bpk-component-navigation-bar/src/BpkNavigationBarButtonLink.js +16 -33
- package/bpk-component-navigation-bar/src/BpkNavigationBarIconButton.js +20 -33
- package/bpk-component-navigation-bar/src/themeAttributes.js +1 -17
- package/bpk-component-nudger/{index.ts → index.js} +4 -5
- package/bpk-component-nudger/src/BpkConfigurableNudger.js +93 -0
- package/bpk-component-nudger/src/BpkNudger.js +42 -0
- package/bpk-component-nudger/src/common-types.js +1 -0
- package/bpk-component-nudger/src/{themeAttributes.ts → themeAttributes.js} +2 -3
- package/{bpk-component-chip/src/BpkSelectableChip.module.scss → bpk-component-nudger-row/index.js} +2 -5
- package/bpk-component-nudger-row/src/BpkNudgerRow.js +69 -0
- package/{bpk-component-aria-live/index.ts → bpk-component-nudger-row/src/BpkNudgerRow.module.css} +6 -14
- package/{bpk-component-button/src/BpkButtonFeatured.module.scss → bpk-component-overlay/index.js} +3 -7
- package/bpk-component-overlay/src/{BpkOverlay.tsx → BpkOverlay.js} +18 -39
- package/bpk-component-page-indicator/index.js +3 -11
- package/bpk-component-page-indicator/src/BpkPageIndicator.js +51 -100
- package/bpk-component-page-indicator/src/NavButton.js +33 -53
- package/bpk-component-pagination/index.js +3 -4
- package/bpk-component-pagination/src/BpkPagination.js +32 -43
- package/bpk-component-pagination/src/BpkPaginationBreak.js +11 -10
- package/bpk-component-pagination/src/BpkPaginationList.js +40 -64
- package/bpk-component-pagination/src/BpkPaginationNudger.js +33 -43
- package/bpk-component-pagination/src/BpkPaginationPage.js +24 -28
- package/bpk-component-pagination/src/themeAttributes.js +2 -9
- package/bpk-component-panel/index.js +2 -3
- package/bpk-component-panel/src/BpkPanel.js +19 -21
- package/bpk-component-phone-input/index.js +2 -10
- package/bpk-component-phone-input/src/BpkPhoneInput.js +76 -133
- package/bpk-component-popover/index.js +4 -18
- package/bpk-component-popover/src/BpkPopover.js +74 -119
- package/bpk-component-popover/src/BpkPopoverPortal.js +54 -103
- package/bpk-component-popover/src/constants.js +4 -7
- package/bpk-component-popover/src/keyboardFocusScope.js +7 -17
- package/bpk-component-popover/src/themeAttributes.js +2 -7
- package/bpk-component-price/index.js +3 -7
- package/bpk-component-price/src/BpkPrice.js +48 -100
- package/bpk-component-price/src/common-types.js +4 -9
- package/bpk-component-progress/index.js +3 -8
- package/bpk-component-progress/src/BpkProgress.js +48 -84
- package/bpk-component-progress/src/themeAttributes.js +1 -5
- package/bpk-component-radio/index.js +3 -8
- package/bpk-component-radio/src/BpkRadio.js +37 -61
- package/bpk-component-radio/src/BpkRadio.module.css +1 -1
- package/bpk-component-radio/src/themeAttributes.js +1 -5
- package/bpk-component-rating/index.js +3 -7
- package/bpk-component-rating/src/BpkRating.js +55 -107
- package/bpk-component-rating/src/common-types.js +6 -8
- package/bpk-component-rtl-toggle/{index.ts → index.js} +3 -4
- package/bpk-component-rtl-toggle/src/{BpkRtlToggle.tsx → BpkRtlToggle.js} +23 -48
- package/bpk-component-rtl-toggle/src/{updateOnDirectionChange.tsx → updateOnDirectionChange.js} +11 -33
- package/bpk-component-rtl-toggle/src/{utils.ts → utils.js} +4 -8
- package/bpk-component-scrollable-calendar/{index.ts → index.js} +6 -14
- package/bpk-component-scrollable-calendar/src/BpkScrollableCalendar.js +22 -0
- package/bpk-component-scrollable-calendar/src/{BpkScrollableCalendarDate.tsx → BpkScrollableCalendarDate.js} +12 -16
- package/bpk-component-scrollable-calendar/src/BpkScrollableCalendarGrid.js +48 -0
- package/bpk-component-scrollable-calendar/src/BpkScrollableCalendarGridList.js +147 -0
- package/bpk-component-scrollable-calendar/src/{utils.ts → utils.js} +6 -19
- package/bpk-component-scrollable-calendar/test-utils.js +211 -0
- package/bpk-component-section-header/{index.ts → index.js} +2 -3
- package/bpk-component-section-header/src/BpkSectionHeader.js +47 -0
- package/bpk-component-section-header/src/BpkSectionHeader.module.css +18 -0
- package/bpk-component-section-list/index.js +4 -9
- package/bpk-component-section-list/src/BpkSectionList.js +13 -19
- package/bpk-component-section-list/src/BpkSectionListItem.js +48 -70
- package/bpk-component-section-list/src/BpkSectionListSection.js +30 -41
- package/bpk-component-select/index.js +3 -9
- package/bpk-component-select/src/BpkSelect.js +25 -70
- package/bpk-component-select/src/themeAttributes.js +1 -1
- package/bpk-component-skip-link/index.js +3 -8
- package/bpk-component-skip-link/src/BpkSkipLink.js +21 -32
- package/bpk-component-skip-link/src/themeAttributes.js +1 -1
- package/bpk-component-slider/index.js +3 -4
- package/bpk-component-slider/src/BpkSlider.js +20 -28
- package/bpk-component-slider/src/themeAttributes.js +1 -1
- package/bpk-component-spinner/index.js +6 -17
- package/bpk-component-spinner/src/BpkExtraLargeSpinner.js +79 -32
- package/bpk-component-spinner/src/BpkLargeSpinner.js +80 -35
- package/bpk-component-spinner/src/BpkSpinner.js +124 -34
- package/bpk-component-spinner/src/spinnerTypes.js +3 -7
- package/bpk-component-spinner/src/themeAttributes.js +1 -5
- package/bpk-component-split-input/index.js +2 -10
- package/bpk-component-split-input/src/BpkInputField.js +33 -35
- package/bpk-component-split-input/src/BpkSplitInput.js +101 -116
- package/bpk-component-star-rating/index.js +8 -22
- package/bpk-component-star-rating/src/BpkInteractiveStar.js +34 -54
- package/bpk-component-star-rating/src/BpkInteractiveStarRating.js +27 -60
- package/bpk-component-star-rating/src/BpkStar.js +46 -68
- package/bpk-component-star-rating/src/BpkStarRating.js +26 -69
- package/bpk-component-star-rating/src/themeAttributes.js +1 -5
- package/bpk-component-star-rating/src/withInteractiveStarRatingState.js +29 -57
- package/bpk-component-switch/index.js +3 -8
- package/bpk-component-switch/src/BpkSwitch.js +32 -45
- package/bpk-component-switch/src/themeAttributes.js +1 -1
- package/bpk-component-table/index.js +7 -19
- package/bpk-component-table/src/BpkTable.js +19 -30
- package/bpk-component-table/src/BpkTableBody.js +7 -14
- package/bpk-component-table/src/BpkTableCell.js +18 -30
- package/bpk-component-table/src/BpkTableHead.js +7 -14
- package/bpk-component-table/src/BpkTableHeadCell.js +16 -29
- package/bpk-component-table/src/BpkTableRow.js +7 -14
- package/bpk-component-text/{index.ts → index.js} +2 -3
- package/bpk-component-text/src/{BpkText.tsx → BpkText.js} +12 -44
- package/bpk-component-text/src/BpkText.module.css +1 -1
- package/bpk-component-textarea/index.js +3 -8
- package/bpk-component-textarea/src/BpkTextarea.js +20 -39
- package/bpk-component-textarea/src/themeAttributes.js +1 -5
- package/bpk-component-theme-toggle/index.js +3 -4
- package/bpk-component-theme-toggle/src/BpkThemeToggle.js +55 -59
- package/bpk-component-theme-toggle/src/theming.js +8 -56
- package/bpk-component-theme-toggle/src/updateOnThemeChange.js +21 -35
- package/bpk-component-theme-toggle/src/utils.js +2 -5
- package/bpk-component-ticket/index.js +2 -7
- package/bpk-component-ticket/src/BpkTicket.js +46 -94
- package/bpk-component-tooltip/index.js +22 -0
- package/bpk-component-tooltip/src/BpkTooltip.js +64 -0
- package/bpk-component-tooltip/src/{BpkTooltipPortal.tsx → BpkTooltipPortal.js} +51 -112
- package/bpk-component-tooltip/src/{constants.ts → constants.js} +6 -4
- package/bpk-react-utils/{index.ts → index.js} +11 -27
- package/bpk-react-utils/src/{Portal.tsx → Portal.js} +55 -159
- package/bpk-react-utils/src/{TransitionInitialMount.tsx → TransitionInitialMount.js} +17 -25
- package/{bpk-component-barchart/src/BpkChartAxis.module.scss → bpk-react-utils/src/cssModules.js} +6 -18
- package/bpk-react-utils/src/deprecated.js +12 -23
- package/bpk-react-utils/src/{deviceDetection.ts → deviceDetection.js} +3 -10
- package/bpk-react-utils/src/{isRTL.ts → isRTL.js} +4 -13
- package/bpk-react-utils/src/{withDefaultProps.tsx → withDefaultProps.js} +15 -37
- package/bpk-react-utils/src/{wrapDisplayName.ts → wrapDisplayName.js} +2 -10
- package/bpk-scrim-utils/{index.ts → index.js} +3 -4
- package/{bpk-component-banner-alert/src/BpkBannerAlertDismissable-test.tsx → bpk-scrim-utils/src/BpkScrim.js} +17 -19
- package/bpk-scrim-utils/src/{scroll-utils.tsx → scroll-utils.js} +3 -33
- package/bpk-scrim-utils/src/{withScrim.tsx → withScrim.js} +33 -70
- package/bpk-storybook-utils/index.js +23 -0
- package/{bpk-scrim-utils/src/BpkScrim.tsx → bpk-storybook-utils/src/BpkDarkExampleWrapper.js} +20 -27
- package/{bpk-component-badge/index.ts → bpk-storybook-utils/src/BpkDarkExampleWrapper.module.css} +6 -12
- package/bpk-storybook-utils/src/BpkStorybookUtils.js +31 -0
- package/bpk-theming/index.js +2 -3
- package/bpk-theming/src/BpkThemeProvider.js +35 -43
- package/index.css +0 -0
- package/package.json +1 -1
- package/bpk-animate-height/README.md +0 -53
- package/bpk-component-accordion/README.md +0 -121
- package/bpk-component-accordion/src/BpkAccordionItem.module.scss +0 -102
- package/bpk-component-aria-live/README.md +0 -39
- package/bpk-component-aria-live/src/BpkAriaLive-test.tsx +0 -59
- package/bpk-component-autosuggest/README.md +0 -124
- package/bpk-component-autosuggest/src/BpkAutosuggest.module.scss +0 -156
- package/bpk-component-badge/README.md +0 -36
- package/bpk-component-badge/src/BpkBadge-test.tsx +0 -70
- package/bpk-component-badge/src/BpkBadge.module.scss +0 -67
- package/bpk-component-banner-alert/README.md +0 -151
- package/bpk-component-banner-alert/index.ts +0 -33
- package/bpk-component-banner-alert/src/AnimateAndFade-test.tsx +0 -65
- package/bpk-component-banner-alert/src/BpkAnimateAndFade.module.scss +0 -53
- package/bpk-component-banner-alert/src/BpkBannerAlert-test.tsx +0 -56
- package/bpk-component-banner-alert/src/BpkBannerAlert.module.scss +0 -151
- package/bpk-component-banner-alert/src/BpkBannerAlertDismissable.tsx +0 -35
- package/bpk-component-banner-alert/src/BpkBannerAlertExpandable-test.tsx +0 -60
- package/bpk-component-banner-alert/src/BpkBannerAlertExpandable.tsx +0 -47
- package/bpk-component-banner-alert/src/BpkBannerAlertInner-test.tsx +0 -196
- package/bpk-component-banner-alert/src/BpkBannerAlertInner.tsx +0 -227
- package/bpk-component-banner-alert/src/accessibility-test.tsx +0 -35
- package/bpk-component-banner-alert/src/common-types.ts +0 -46
- package/bpk-component-banner-alert/src/themeAttributes-test.ts +0 -30
- package/bpk-component-banner-alert/src/withBannerAlertState-test.tsx +0 -142
- package/bpk-component-barchart/README.md +0 -186
- package/bpk-component-barchart/data.json +0 -20
- package/bpk-component-barchart/src/BpkBarchartBar.module.scss +0 -70
- package/bpk-component-barchart/src/BpkChartDataTable.module.scss +0 -28
- package/bpk-component-barchart/src/BpkChartGridLines.module.scss +0 -26
- package/bpk-component-blockquote/README.md +0 -32
- package/bpk-component-blockquote/src/BpkBlockquote.module.scss +0 -29
- package/bpk-component-breadcrumb/README.md +0 -56
- package/bpk-component-breadcrumb/src/BpkBreadcrumb.module.scss +0 -27
- package/bpk-component-breadcrumb/src/BpkBreadcrumbItem.module.scss +0 -40
- package/bpk-component-breakpoint/README.md +0 -31
- package/bpk-component-breakpoint/src/BpkBreakpoint-test.tsx +0 -102
- package/bpk-component-breakpoint/src/accessibility-test.tsx +0 -36
- package/bpk-component-button/README.md +0 -50
- package/bpk-component-button/src/BpkButtonBase.module.scss +0 -50
- package/bpk-component-button/src/BpkButtonDestructive.module.scss +0 -24
- package/bpk-component-button/src/BpkButtonLinkOnDark.module.scss +0 -23
- package/bpk-component-button/src/BpkButtonPrimaryOnDark.module.scss +0 -23
- package/bpk-component-button/src/BpkButtonPrimaryOnLight.module.scss +0 -23
- package/bpk-component-button/src/BpkButtonSecondaryOnDark.module.scss +0 -23
- package/bpk-component-button/src/BpkButtonV2/BpkButton-test.tsx +0 -125
- package/bpk-component-button/src/BpkButtonV2/BpkButton.module.scss +0 -81
- package/bpk-component-button/src/BpkButtonV2/accessibility-test.tsx +0 -36
- package/bpk-component-button/src/BpkButtonV2/common-types.tsx +0 -54
- package/bpk-component-calendar/DOCS.md +0 -23
- package/bpk-component-calendar/README.md +0 -382
- package/bpk-component-calendar/index.ts +0 -74
- package/bpk-component-calendar/src/BpkCalendar.module.scss +0 -42
- package/bpk-component-calendar/src/BpkCalendarContainer-test.tsx +0 -389
- package/bpk-component-calendar/src/BpkCalendarContainer.tsx +0 -401
- package/bpk-component-calendar/src/BpkCalendarDate-test.tsx +0 -82
- package/bpk-component-calendar/src/BpkCalendarDate.module.scss +0 -122
- package/bpk-component-calendar/src/BpkCalendarGrid-test.tsx +0 -134
- package/bpk-component-calendar/src/BpkCalendarGrid.module.scss +0 -81
- package/bpk-component-calendar/src/BpkCalendarGrid.tsx +0 -193
- package/bpk-component-calendar/src/BpkCalendarGridHeader.module.scss +0 -50
- package/bpk-component-calendar/src/BpkCalendarGridHeader.tsx +0 -99
- package/bpk-component-calendar/src/BpkCalendarGridTransition-test.tsx +0 -115
- package/bpk-component-calendar/src/BpkCalendarGridTransition.module.scss +0 -47
- package/bpk-component-calendar/src/BpkCalendarGridTransition.tsx +0 -240
- package/bpk-component-calendar/src/BpkCalendarNav-test.tsx +0 -116
- package/bpk-component-calendar/src/BpkCalendarNav.module.scss +0 -89
- package/bpk-component-calendar/src/BpkCalendarNav.tsx +0 -190
- package/bpk-component-calendar/src/Week-test.tsx +0 -220
- package/bpk-component-calendar/src/Week.tsx +0 -472
- package/bpk-component-calendar/src/_variables.scss +0 -22
- package/bpk-component-calendar/src/accessibility-test.tsx +0 -74
- package/bpk-component-calendar/src/composeCalendar-test.tsx +0 -163
- package/bpk-component-calendar/src/composeCalendar.tsx +0 -187
- package/bpk-component-calendar/src/custom-proptypes.ts +0 -52
- package/bpk-component-calendar/src/themeAttributes-test.ts +0 -36
- package/bpk-component-calendar/src/themeAttributes.ts +0 -30
- package/bpk-component-calendar/test-utils.ts +0 -303
- package/bpk-component-card/README.md +0 -103
- package/bpk-component-card/src/BpkCard-test.tsx +0 -100
- package/bpk-component-card/src/BpkCard.module.scss +0 -38
- package/bpk-component-card/src/BpkCardWrapper-test.tsx +0 -64
- package/bpk-component-card/src/BpkCardWrapper.module.scss +0 -69
- package/bpk-component-card/src/BpkDividedCard-test.tsx +0 -96
- package/bpk-component-card/src/BpkDividedCard.module.scss +0 -71
- package/bpk-component-card/src/BpkDividedCard.tsx +0 -83
- package/bpk-component-checkbox/README.md +0 -44
- package/bpk-component-checkbox/src/BpkCheckbox.module.scss +0 -78
- package/bpk-component-chip/README.md +0 -135
- package/bpk-component-chip/index.ts +0 -33
- package/bpk-component-chip/src/BpkDismissibleChip-test.tsx +0 -84
- package/bpk-component-chip/src/BpkDropdownChip-test.tsx +0 -76
- package/bpk-component-chip/src/BpkSelectableChip-test.tsx +0 -100
- package/bpk-component-chip/src/BpkSelectableChip.tsx +0 -81
- package/bpk-component-chip/src/accessibility-test.tsx +0 -47
- package/bpk-component-chip/src/themeAttributes-test.ts +0 -34
- package/bpk-component-chip/src/themeAttributes.ts +0 -28
- package/bpk-component-close-button/README.md +0 -24
- package/bpk-component-close-button/src/BpkCloseButton.module.scss +0 -52
- package/bpk-component-code/README.md +0 -40
- package/bpk-component-code/src/BpkCode.module.scss +0 -27
- package/bpk-component-code/src/BpkCodeBlock.module.scss +0 -33
- package/bpk-component-content-cards/README.md +0 -37
- package/bpk-component-content-cards/src/BpkContentCard.module.scss +0 -87
- package/bpk-component-content-cards/src/BpkContentCards.module.scss +0 -51
- package/bpk-component-datatable/README.md +0 -196
- package/bpk-component-datatable/src/BpkDataTable.module.scss +0 -90
- package/bpk-component-datatable/src/BpkDataTableHeader.module.scss +0 -65
- package/bpk-component-datepicker/README.md +0 -179
- package/bpk-component-datepicker/src/BpkDatepicker-test.tsx +0 -390
- package/bpk-component-datepicker/src/BpkDatepicker.module.scss +0 -30
- package/bpk-component-datepicker/src/BpkDatepicker.tsx +0 -390
- package/bpk-component-datepicker/src/accessibility-test.tsx +0 -105
- package/bpk-component-datepicker/src/themeAttibutes-test.ts +0 -40
- package/bpk-component-description-list/README.md +0 -43
- package/bpk-component-description-list/src/BpkDescriptionList.module.scss +0 -37
- package/bpk-component-dialog/README.md +0 -103
- package/bpk-component-dialog/index.ts +0 -25
- package/bpk-component-dialog/src/BpkDialog-test.tsx +0 -184
- package/bpk-component-dialog/src/BpkDialog.module.scss +0 -80
- package/bpk-component-dialog/src/BpkDialog.tsx +0 -78
- package/bpk-component-dialog/src/BpkDialogInner.module.scss +0 -64
- package/bpk-component-dialog/src/BpkDialogInner.tsx +0 -72
- package/bpk-component-dialog/src/accessibility-test.tsx +0 -45
- package/bpk-component-dialog/src/common-types.ts +0 -48
- package/bpk-component-drawer/README.md +0 -88
- package/bpk-component-drawer/src/BpkDrawerContent.module.scss +0 -107
- package/bpk-component-fieldset/README.md +0 -71
- package/bpk-component-fieldset/src/BpkFieldset.module.scss +0 -39
- package/bpk-component-flare/README.md +0 -49
- package/bpk-component-flare/src/__generated__/js/corner-radius.d.ts.map +0 -1
- package/bpk-component-flare/src/__generated__/js/corner-radius.tsx +0 -5
- package/bpk-component-flare/src/__generated__/js/pointer.d.ts.map +0 -1
- package/bpk-component-flare/src/__generated__/js/pointer.tsx +0 -5
- package/bpk-component-flare/src/bpk-content-bubble.module.scss +0 -61
- package/bpk-component-flare/src/bpk-flare-bar.module.scss +0 -75
- package/bpk-component-flare/src/svgs/corner-radius.svg +0 -1
- package/bpk-component-flare/src/svgs/pointer.svg +0 -1
- package/bpk-component-floating-notification/README.md +0 -47
- package/bpk-component-floating-notification/src/BpkFloatingNotification.module.scss +0 -85
- package/bpk-component-form-validation/README.md +0 -30
- package/bpk-component-form-validation/src/BpkFormValidation.module.scss +0 -44
- package/bpk-component-graphic-promotion/README.md +0 -67
- package/bpk-component-graphic-promotion/src/BpkGraphicPromo-test.tsx +0 -132
- package/bpk-component-graphic-promotion/src/BpkGraphicPromo.module.scss +0 -270
- package/bpk-component-graphic-promotion/src/BpkGraphicPromo.tsx +0 -201
- package/bpk-component-graphic-promotion/src/accessibility-test.tsx +0 -146
- package/bpk-component-grid-toggle/README.md +0 -24
- package/bpk-component-grid-toggle/src/BpkGridToggle.module.scss +0 -52
- package/bpk-component-horizontal-nav/README.md +0 -101
- package/bpk-component-horizontal-nav/src/BpkHorizontalNav.module.scss +0 -37
- package/bpk-component-horizontal-nav/src/BpkHorizontalNavItem.module.scss +0 -152
- package/bpk-component-icon/README.md +0 -74
- package/bpk-component-icon/src/BpkIcon.module.scss +0 -33
- package/bpk-component-icon/src/classNameModifierHOCFactory-test.tsx +0 -82
- package/bpk-component-icon/src/classNameModifierHOCFactory.tsx +0 -47
- package/bpk-component-icon/src/withAlignment-test.tsx +0 -96
- package/bpk-component-icon/src/withAlignment.tsx +0 -52
- package/bpk-component-icon/src/withDescription-test.tsx +0 -32
- package/bpk-component-image/README.md +0 -139
- package/bpk-component-image/index.ts +0 -34
- package/bpk-component-image/src/BpkBackgroundImage-test.tsx +0 -131
- package/bpk-component-image/src/BpkBackgroundImage.module.scss +0 -46
- package/bpk-component-image/src/BpkBackgroundImage.tsx +0 -161
- package/bpk-component-image/src/BpkImage-test.tsx +0 -149
- package/bpk-component-image/src/BpkImage.module.scss +0 -89
- package/bpk-component-image/src/BpkImage.tsx +0 -214
- package/bpk-component-image/src/BpkImageBorderRadiusStyles.ts +0 -21
- package/bpk-component-image/src/accessibility-test.tsx +0 -64
- package/bpk-component-image/src/withLazyLoading-test.tsx +0 -96
- package/bpk-component-infinite-scroll/README.md +0 -183
- package/bpk-component-infinite-scroll/src/withInfiniteScroll-test.flow.js +0 -102
- package/bpk-component-infinite-scroll/src/withInfiniteScroll.module.scss +0 -25
- package/bpk-component-input/README.md +0 -117
- package/bpk-component-input/index.ts +0 -40
- package/bpk-component-input/src/BpkClearButton-test.tsx +0 -42
- package/bpk-component-input/src/BpkClearButton.module.scss +0 -40
- package/bpk-component-input/src/BpkInput-test.tsx +0 -257
- package/bpk-component-input/src/BpkInput.module.scss +0 -86
- package/bpk-component-input/src/accessibility-test.tsx +0 -36
- package/bpk-component-input/src/common-types-test.ts +0 -173
- package/bpk-component-input/src/themeAttributes-test.ts +0 -25
- package/bpk-component-input/src/withOpenEvents-test.tsx +0 -168
- package/bpk-component-label/README.md +0 -27
- package/bpk-component-label/src/BpkLabel.module.scss +0 -47
- package/bpk-component-link/README.md +0 -66
- package/bpk-component-link/src/BpkLink.module.scss +0 -31
- package/bpk-component-list/README.md +0 -48
- package/bpk-component-list/src/BpkList.module.scss +0 -37
- package/bpk-component-loading-button/README.md +0 -45
- package/bpk-component-loading-button/src/BpkLoadingButton.module.scss +0 -67
- package/bpk-component-map/README.md +0 -209
- package/bpk-component-map/src/BpkIconMarker.module.scss +0 -79
- package/bpk-component-map/src/BpkIconMarkerBackground.module.scss +0 -53
- package/bpk-component-map/src/BpkPriceMarker.module.scss +0 -148
- package/bpk-component-map/src/DefaultLoadingElement.module.scss +0 -28
- package/bpk-component-mobile-scroll-container/README.md +0 -71
- package/bpk-component-mobile-scroll-container/src/BpkMobileScrollContainer.module.scss +0 -52
- package/bpk-component-modal/README.md +0 -113
- package/bpk-component-modal/src/BpkModal-test.tsx +0 -46
- package/bpk-component-modal/src/BpkModal.module.scss +0 -46
- package/bpk-component-modal/src/BpkModal.tsx +0 -109
- package/bpk-component-modal/src/BpkModalInner-test.tsx +0 -202
- package/bpk-component-modal/src/BpkModalInner.module.scss +0 -125
- package/bpk-component-modal/src/BpkModalInner.tsx +0 -156
- package/bpk-component-modal/src/BpkModalV2/BpKModal-test.tsx +0 -318
- package/bpk-component-modal/src/BpkModalV2/BpKModal.module.scss +0 -178
- package/bpk-component-modal/src/BpkModalV2/BpkModal.tsx +0 -190
- package/bpk-component-modal/src/BpkModalV2/README.md +0 -90
- package/bpk-component-modal/src/BpkModalV2/accessibility-test.tsx +0 -42
- package/bpk-component-modal/src/accessibility-test.tsx +0 -46
- package/bpk-component-modal/src/themeAttributes-test.ts +0 -30
- package/bpk-component-navigation-bar/README.md +0 -109
- package/bpk-component-navigation-bar/src/BpkNavigationBar.module.scss +0 -78
- package/bpk-component-navigation-bar/src/BpkNavigationBarButtonLink.module.scss +0 -51
- package/bpk-component-navigation-bar/src/BpkNavigationBarIconButton.module.scss +0 -43
- package/bpk-component-nudger/README.md +0 -180
- package/bpk-component-nudger/src/BpkConfigurableNudger.tsx +0 -119
- package/bpk-component-nudger/src/BpkNudger-test.tsx +0 -197
- package/bpk-component-nudger/src/BpkNudger.module.scss +0 -50
- package/bpk-component-nudger/src/BpkNudger.tsx +0 -50
- package/bpk-component-nudger/src/accessibility-test.tsx +0 -46
- package/bpk-component-nudger/src/themeAttributes-test.ts +0 -35
- package/bpk-component-nudger-row/README.md +0 -57
- package/bpk-component-nudger-row/index.ts +0 -24
- package/bpk-component-nudger-row/src/BpkNudgerRow-test.tsx +0 -74
- package/bpk-component-nudger-row/src/BpkNudgerRow.module.scss +0 -35
- package/bpk-component-nudger-row/src/BpkNudgerRow.tsx +0 -85
- package/bpk-component-nudger-row/src/accessibility-test.tsx +0 -42
- package/bpk-component-overlay/README.md +0 -47
- package/bpk-component-overlay/index.ts +0 -27
- package/bpk-component-overlay/src/BpkOverlay-test.tsx +0 -70
- package/bpk-component-overlay/src/BpkOverlay.module.scss +0 -163
- package/bpk-component-overlay/src/accessibility-test.tsx +0 -35
- package/bpk-component-page-indicator/README.md +0 -41
- package/bpk-component-page-indicator/src/BpkPageIndicator.module.scss +0 -91
- package/bpk-component-pagination/README.md +0 -56
- package/bpk-component-pagination/src/BpkPagination.module.scss +0 -22
- package/bpk-component-pagination/src/BpkPaginationList.module.scss +0 -46
- package/bpk-component-pagination/src/BpkPaginationNudger.module.scss +0 -34
- package/bpk-component-pagination/src/BpkPaginationPage.module.scss +0 -59
- package/bpk-component-panel/README.md +0 -30
- package/bpk-component-panel/src/BpkPanel.module.scss +0 -31
- package/bpk-component-phone-input/README.md +0 -98
- package/bpk-component-phone-input/src/BpkPhoneInput.module.scss +0 -42
- package/bpk-component-popover/README.md +0 -138
- package/bpk-component-popover/src/BpkPopover.module.scss +0 -127
- package/bpk-component-price/README.md +0 -39
- package/bpk-component-price/src/BpkPrice.module.scss +0 -74
- package/bpk-component-progress/README.md +0 -53
- package/bpk-component-progress/src/BpkProgress.module.scss +0 -64
- package/bpk-component-radio/README.md +0 -40
- package/bpk-component-radio/src/BpkRadio.module.scss +0 -85
- package/bpk-component-rating/README.md +0 -84
- package/bpk-component-rating/src/BpkRating.module.scss +0 -83
- package/bpk-component-rtl-toggle/README.md +0 -23
- package/bpk-component-rtl-toggle/src/BpkRtlToggle-test.tsx +0 -33
- package/bpk-component-rtl-toggle/src/accessibility-test.tsx +0 -30
- package/bpk-component-rtl-toggle/src/updateOnDirectionChange-test.tsx +0 -48
- package/bpk-component-scrollable-calendar/README.md +0 -100
- package/bpk-component-scrollable-calendar/src/BpkScrollableCalendar-test.tsx +0 -101
- package/bpk-component-scrollable-calendar/src/BpkScrollableCalendar.tsx +0 -35
- package/bpk-component-scrollable-calendar/src/BpkScrollableCalendarDate-test.tsx +0 -74
- package/bpk-component-scrollable-calendar/src/BpkScrollableCalendarGrid-test.tsx +0 -142
- package/bpk-component-scrollable-calendar/src/BpkScrollableCalendarGrid.module.scss +0 -31
- package/bpk-component-scrollable-calendar/src/BpkScrollableCalendarGrid.tsx +0 -60
- package/bpk-component-scrollable-calendar/src/BpkScrollableCalendarGridList-test.tsx +0 -113
- package/bpk-component-scrollable-calendar/src/BpkScrollableCalendarGridList.module.scss +0 -36
- package/bpk-component-scrollable-calendar/src/BpkScrollableCalendarGridList.tsx +0 -208
- package/bpk-component-scrollable-calendar/src/accessibility-test.tsx +0 -69
- package/bpk-component-scrollable-calendar/src/utils-test.ts +0 -43
- package/bpk-component-scrollable-calendar/test-utils.ts +0 -275
- package/bpk-component-section-header/README.md +0 -28
- package/bpk-component-section-header/src/BpkSectionHeader-test.tsx +0 -64
- package/bpk-component-section-header/src/BpkSectionHeader.module.scss +0 -47
- package/bpk-component-section-header/src/BpkSectionHeader.tsx +0 -67
- package/bpk-component-section-header/src/accessibility-test.tsx +0 -35
- package/bpk-component-section-list/README.md +0 -49
- package/bpk-component-section-list/src/BpkSectionListItem.module.scss +0 -54
- package/bpk-component-section-list/src/BpkSectionListSection.module.scss +0 -35
- package/bpk-component-select/README.md +0 -62
- package/bpk-component-select/src/BpkSelect.module.scss +0 -131
- package/bpk-component-skip-link/README.md +0 -27
- package/bpk-component-skip-link/src/BpkSkipLink.module.scss +0 -50
- package/bpk-component-slider/README.md +0 -40
- package/bpk-component-slider/src/BpkSlider.module.scss +0 -86
- package/bpk-component-spinner/README.md +0 -37
- package/bpk-component-spinner/changelog.yml +0 -55
- package/bpk-component-spinner/src/BpkSpinner.module.scss +0 -58
- package/bpk-component-split-input/README.md +0 -39
- package/bpk-component-split-input/src/BpkInputField.module.scss +0 -34
- package/bpk-component-split-input/src/BpkSplitInput.module.scss +0 -36
- package/bpk-component-star-rating/README.md +0 -96
- package/bpk-component-star-rating/src/BpkInteractiveStar.module.scss +0 -66
- package/bpk-component-star-rating/src/BpkStar.module.scss +0 -63
- package/bpk-component-star-rating/src/BpkStarRating.module.scss +0 -21
- package/bpk-component-switch/README.md +0 -34
- package/bpk-component-switch/src/BpkSwitch.module.scss +0 -92
- package/bpk-component-table/README.md +0 -62
- package/bpk-component-table/src/BpkTable.module.scss +0 -31
- package/bpk-component-text/README.md +0 -69
- package/bpk-component-text/src/BpkText-test.tsx +0 -84
- package/bpk-component-text/src/BpkText.module.scss +0 -131
- package/bpk-component-text/src/accessibility-test.tsx +0 -36
- package/bpk-component-textarea/README.md +0 -31
- package/bpk-component-textarea/src/BpkTextarea.module.scss +0 -33
- package/bpk-component-theme-toggle/README.md +0 -26
- package/bpk-component-theme-toggle/src/BpkThemeToggle.module.scss +0 -25
- package/bpk-component-ticket/README.md +0 -34
- package/bpk-component-ticket/src/BpkTicket.module.scss +0 -144
- package/bpk-component-tooltip/README.md +0 -65
- package/bpk-component-tooltip/index.ts +0 -26
- package/bpk-component-tooltip/src/BpkTooltip-test.tsx +0 -62
- package/bpk-component-tooltip/src/BpkTooltip.module.scss +0 -149
- package/bpk-component-tooltip/src/BpkTooltip.tsx +0 -89
- package/bpk-component-tooltip/src/BpkTooltipPortal-test.tsx +0 -94
- package/bpk-component-tooltip/src/accessibility-test.tsx +0 -34
- package/bpk-react-utils/README.md +0 -246
- package/bpk-react-utils/src/Portal-test.tsx +0 -794
- package/bpk-react-utils/src/TransitionInitialMount-test.tsx +0 -37
- package/bpk-react-utils/src/accessibility-test.tsx +0 -73
- package/bpk-react-utils/src/cssModules-test.ts +0 -65
- package/bpk-react-utils/src/cssModules.ts +0 -27
- package/bpk-react-utils/src/deviceDetection-test.ts +0 -92
- package/bpk-react-utils/src/isRTL-test.ts +0 -53
- package/bpk-react-utils/src/withDefaultProps-test.tsx +0 -58
- package/bpk-react-utils/src/wrapDisplayName-test.tsx +0 -37
- package/bpk-scrim-utils/README.md +0 -47
- package/bpk-scrim-utils/src/BpkScrim-test.tsx +0 -28
- package/bpk-scrim-utils/src/accessibility-test.tsx +0 -47
- package/bpk-scrim-utils/src/bpk-scrim-content.module.scss +0 -32
- package/bpk-scrim-utils/src/bpk-scrim.module.scss +0 -45
- package/bpk-scrim-utils/src/withScrim-test.tsx +0 -222
- package/bpk-theming/README.md +0 -41
- /package/bpk-component-flare/src/{__generated__/js/corner-radius.d.ts → corner-radius.d.ts} +0 -0
- /package/bpk-component-flare/src/{__generated__/js/pointer.d.ts → pointer.d.ts} +0 -0
|
@@ -14,22 +14,9 @@
|
|
|
14
14
|
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
|
15
15
|
* See the License for the specific language governing permissions and
|
|
16
16
|
* limitations under the License.
|
|
17
|
-
*/
|
|
18
|
-
|
|
19
|
-
/* @flow strict */
|
|
20
|
-
|
|
21
|
-
// This file exists to break a cycle that would otherwise happen between
|
|
17
|
+
*/ // This file exists to break a cycle that would otherwise happen between
|
|
22
18
|
// BpkDataTableColumn.js and common-types.js
|
|
23
|
-
|
|
24
19
|
export const SORT_DIRECTION_TYPES = {
|
|
25
20
|
ASC: 'ASC',
|
|
26
|
-
DESC: 'DESC'
|
|
27
|
-
};
|
|
28
|
-
|
|
29
|
-
export type SortDirectionType = 'ASC' | ' DESC';
|
|
30
|
-
|
|
31
|
-
export type SortProps = {
|
|
32
|
-
sortBy: ?string,
|
|
33
|
-
sortDirection: ?SortDirectionType,
|
|
34
|
-
sort: ?Function,
|
|
35
|
-
};
|
|
21
|
+
DESC: 'DESC'
|
|
22
|
+
};
|
|
@@ -14,74 +14,90 @@
|
|
|
14
14
|
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
|
15
15
|
* See the License for the specific language governing permissions and
|
|
16
16
|
* limitations under the License.
|
|
17
|
-
*/
|
|
18
|
-
/* @flow strict */
|
|
19
|
-
|
|
20
|
-
// TODO: Remove these functions once we want to change the API to match the react-table library API
|
|
17
|
+
*/ // TODO: Remove these functions once we want to change the API to match the react-table library API
|
|
21
18
|
// To maintain backwards compatibility with the old API of BpkDataTable which takes columns as children
|
|
22
19
|
// The `react-table` library however expects columns as an array of objects
|
|
23
20
|
// eslint-disable-next-line import/prefer-default-export
|
|
24
|
-
export const getColumns =
|
|
25
|
-
|
|
26
|
-
|
|
27
|
-
|
|
28
|
-
|
|
29
|
-
|
|
30
|
-
|
|
31
|
-
|
|
32
|
-
|
|
33
|
-
|
|
34
|
-
|
|
35
|
-
}
|
|
36
|
-
|
|
37
|
-
|
|
38
|
-
|
|
39
|
-
|
|
40
|
-
|
|
41
|
-
|
|
42
|
-
|
|
43
|
-
|
|
44
|
-
|
|
45
|
-
|
|
46
|
-
|
|
47
|
-
|
|
48
|
-
|
|
49
|
-
column: { id: dataKey },
|
|
50
|
-
row: { values: rowData },
|
|
51
|
-
}) => cellDataGetter({ dataKey, rowData });
|
|
52
|
-
|
|
53
|
-
const columnHeaderRenderer = ({
|
|
54
|
-
column: { disableSortBy: disableSort, id: dataKey, label },
|
|
55
|
-
}) => headerRenderer({ dataKey, label, disableSort });
|
|
56
|
-
|
|
57
|
-
const {
|
|
58
|
-
className,
|
|
21
|
+
export const getColumns = columns => columns.map(column => {
|
|
22
|
+
const {
|
|
23
|
+
cellDataGetter,
|
|
24
|
+
cellRenderer,
|
|
25
|
+
headerRenderer
|
|
26
|
+
} = column.props;
|
|
27
|
+
// To maintain backwards compatibility with the old API of BpkDataTable we rename the parameters
|
|
28
|
+
// And create an interface so that the function signature doesn't depend on the underlying library
|
|
29
|
+
const columnCellRenderer = ({
|
|
30
|
+
column: {
|
|
31
|
+
id: dataKey
|
|
32
|
+
},
|
|
33
|
+
columns: columnsData,
|
|
34
|
+
row: {
|
|
35
|
+
id: rowID,
|
|
36
|
+
values: rowData
|
|
37
|
+
},
|
|
38
|
+
sortedRows,
|
|
39
|
+
value: cellData
|
|
40
|
+
}) => {
|
|
41
|
+
const columnIndex = columnsData.map(col => col.id).indexOf(dataKey);
|
|
42
|
+
const rowIndex = sortedRows.map(row => row.id).indexOf(rowID);
|
|
43
|
+
return cellRenderer({
|
|
44
|
+
cellData,
|
|
45
|
+
columnIndex,
|
|
59
46
|
dataKey,
|
|
60
|
-
|
|
61
|
-
|
|
62
|
-
|
|
63
|
-
|
|
64
|
-
|
|
65
|
-
|
|
66
|
-
|
|
67
|
-
|
|
68
|
-
|
|
69
|
-
|
|
70
|
-
|
|
71
|
-
|
|
72
|
-
|
|
73
|
-
|
|
74
|
-
|
|
75
|
-
|
|
76
|
-
|
|
47
|
+
rowData,
|
|
48
|
+
rowIndex
|
|
49
|
+
});
|
|
50
|
+
};
|
|
51
|
+
const columnCellDataGetter = ({
|
|
52
|
+
column: {
|
|
53
|
+
id: dataKey
|
|
54
|
+
},
|
|
55
|
+
row: {
|
|
56
|
+
values: rowData
|
|
57
|
+
}
|
|
58
|
+
}) => cellDataGetter({
|
|
59
|
+
dataKey,
|
|
60
|
+
rowData
|
|
61
|
+
});
|
|
62
|
+
const columnHeaderRenderer = ({
|
|
63
|
+
column: {
|
|
77
64
|
disableSortBy: disableSort,
|
|
78
|
-
|
|
79
|
-
|
|
80
|
-
|
|
81
|
-
|
|
82
|
-
|
|
83
|
-
|
|
84
|
-
|
|
85
|
-
width,
|
|
86
|
-
};
|
|
65
|
+
id: dataKey,
|
|
66
|
+
label
|
|
67
|
+
}
|
|
68
|
+
}) => headerRenderer({
|
|
69
|
+
dataKey,
|
|
70
|
+
label,
|
|
71
|
+
disableSort
|
|
87
72
|
});
|
|
73
|
+
const {
|
|
74
|
+
className,
|
|
75
|
+
dataKey,
|
|
76
|
+
defaultSortDirection,
|
|
77
|
+
disableSort,
|
|
78
|
+
flexGrow,
|
|
79
|
+
headerClassName,
|
|
80
|
+
headerStyle,
|
|
81
|
+
label,
|
|
82
|
+
minWidth,
|
|
83
|
+
style,
|
|
84
|
+
width
|
|
85
|
+
} = column.props;
|
|
86
|
+
return {
|
|
87
|
+
Header: headerRenderer ? columnHeaderRenderer : label,
|
|
88
|
+
accessor: dataKey,
|
|
89
|
+
...((cellRenderer || cellDataGetter) && {
|
|
90
|
+
Cell: columnCellRenderer || columnCellDataGetter
|
|
91
|
+
}),
|
|
92
|
+
className,
|
|
93
|
+
disableSortBy: disableSort,
|
|
94
|
+
defaultSortDirection,
|
|
95
|
+
flexGrow,
|
|
96
|
+
headerClassName,
|
|
97
|
+
headerStyle,
|
|
98
|
+
label,
|
|
99
|
+
minWidth,
|
|
100
|
+
style,
|
|
101
|
+
width
|
|
102
|
+
};
|
|
103
|
+
});
|
|
@@ -16,10 +16,8 @@
|
|
|
16
16
|
* limitations under the License.
|
|
17
17
|
*/
|
|
18
18
|
|
|
19
|
-
import { CALENDAR_SELECTION_TYPE } from
|
|
20
|
-
|
|
21
|
-
import
|
|
22
|
-
import themeAttributes from './src/themeAttributes';
|
|
23
|
-
|
|
19
|
+
import { CALENDAR_SELECTION_TYPE } from "../bpk-component-calendar";
|
|
20
|
+
import BpkDatepicker from "./src/BpkDatepicker";
|
|
21
|
+
import themeAttributes from "./src/themeAttributes";
|
|
24
22
|
export default BpkDatepicker;
|
|
25
|
-
export { CALENDAR_SELECTION_TYPE, themeAttributes };
|
|
23
|
+
export { CALENDAR_SELECTION_TYPE, themeAttributes };
|
|
@@ -0,0 +1,267 @@
|
|
|
1
|
+
/*
|
|
2
|
+
* Backpack - Skyscanner's Design System
|
|
3
|
+
*
|
|
4
|
+
* Copyright 2016 Skyscanner Ltd
|
|
5
|
+
*
|
|
6
|
+
* Licensed under the Apache License, Version 2.0 (the "License");
|
|
7
|
+
* you may not use this file except in compliance with the License.
|
|
8
|
+
* You may obtain a copy of the License at
|
|
9
|
+
*
|
|
10
|
+
* http://www.apache.org/licenses/LICENSE-2.0
|
|
11
|
+
*
|
|
12
|
+
* Unless required by applicable law or agreed to in writing, software
|
|
13
|
+
* distributed under the License is distributed on an "AS IS" BASIS,
|
|
14
|
+
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
|
15
|
+
* See the License for the specific language governing permissions and
|
|
16
|
+
* limitations under the License.
|
|
17
|
+
*/
|
|
18
|
+
|
|
19
|
+
import { createRef, Component } from 'react';
|
|
20
|
+
import BpkInput, { withOpenEvents } from "../../bpk-component-input";
|
|
21
|
+
import BpkModal from "../../bpk-component-modal";
|
|
22
|
+
// @ts-expect-error Untyped import. See `decisions/imports-ts-suppressions.md`.
|
|
23
|
+
import BpkPopover from "../../bpk-component-popover";
|
|
24
|
+
import { cssModules } from "../../bpk-react-utils";
|
|
25
|
+
import BpkBreakpoint, { BREAKPOINTS } from "../../bpk-component-breakpoint";
|
|
26
|
+
import { composeCalendar, BpkCalendarGridHeader, BpkCalendarGrid, BpkCalendarDate, withCalendarState, CALENDAR_SELECTION_TYPE, DateUtils, BpkCalendarNav } from "../../bpk-component-calendar";
|
|
27
|
+
import STYLES from "./BpkDatepicker.module.css";
|
|
28
|
+
import { jsx as _jsx } from "react/jsx-runtime";
|
|
29
|
+
import { Fragment as _Fragment } from "react/jsx-runtime";
|
|
30
|
+
import { jsxs as _jsxs } from "react/jsx-runtime";
|
|
31
|
+
const getClassName = cssModules(STYLES);
|
|
32
|
+
const Input = withOpenEvents(BpkInput);
|
|
33
|
+
const DefaultCalendar = withCalendarState(composeCalendar(BpkCalendarNav, BpkCalendarGridHeader, BpkCalendarGrid, BpkCalendarDate));
|
|
34
|
+
class BpkDatepicker extends Component {
|
|
35
|
+
static defaultProps = {
|
|
36
|
+
calendarComponent: DefaultCalendar,
|
|
37
|
+
inputComponent: null,
|
|
38
|
+
dateModifiers: {},
|
|
39
|
+
inputProps: {},
|
|
40
|
+
fixedWidth: true,
|
|
41
|
+
markOutsideDays: true,
|
|
42
|
+
markToday: DefaultCalendar.defaultProps.markToday,
|
|
43
|
+
maxDate: DefaultCalendar.defaultProps.maxDate,
|
|
44
|
+
minDate: DefaultCalendar.defaultProps.minDate,
|
|
45
|
+
nextMonthLabel: null,
|
|
46
|
+
onDateSelect: null,
|
|
47
|
+
onOpenChange: null,
|
|
48
|
+
onMonthChange: null,
|
|
49
|
+
previousMonthLabel: null,
|
|
50
|
+
selectionConfiguration: {
|
|
51
|
+
type: CALENDAR_SELECTION_TYPE.single,
|
|
52
|
+
date: null
|
|
53
|
+
},
|
|
54
|
+
initiallyFocusedDate: null,
|
|
55
|
+
renderTarget: null,
|
|
56
|
+
isOpen: false,
|
|
57
|
+
valid: null
|
|
58
|
+
};
|
|
59
|
+
constructor(props) {
|
|
60
|
+
super(props);
|
|
61
|
+
this.state = {
|
|
62
|
+
isOpen: props.isOpen
|
|
63
|
+
};
|
|
64
|
+
this.inputRef = /*#__PURE__*/createRef();
|
|
65
|
+
}
|
|
66
|
+
componentDidUpdate(prevProps, prevState) {
|
|
67
|
+
const {
|
|
68
|
+
isOpen
|
|
69
|
+
} = this.props;
|
|
70
|
+
if (prevProps.isOpen !== isOpen && prevState.isOpen !== isOpen) {
|
|
71
|
+
if (isOpen) {
|
|
72
|
+
this.onOpen();
|
|
73
|
+
} else {
|
|
74
|
+
this.onClose();
|
|
75
|
+
}
|
|
76
|
+
}
|
|
77
|
+
}
|
|
78
|
+
onOpen = () => {
|
|
79
|
+
this.setState({
|
|
80
|
+
isOpen: true
|
|
81
|
+
});
|
|
82
|
+
if (this.props.onOpenChange) {
|
|
83
|
+
this.props.onOpenChange(true);
|
|
84
|
+
}
|
|
85
|
+
};
|
|
86
|
+
onClose = () => {
|
|
87
|
+
this.setState({
|
|
88
|
+
isOpen: false
|
|
89
|
+
});
|
|
90
|
+
if (this.props.onOpenChange) {
|
|
91
|
+
this.props.onOpenChange(false);
|
|
92
|
+
}
|
|
93
|
+
};
|
|
94
|
+
|
|
95
|
+
/**
|
|
96
|
+
* Gets the correct label for the input field to be supplied to the aria-label
|
|
97
|
+
* @param {Object} selectionConfiguration current selection configuration
|
|
98
|
+
* @param {Function} formatDateFull function supplied to format date
|
|
99
|
+
* @returns {String} date string
|
|
100
|
+
*/
|
|
101
|
+
getLabel = (selectionConfiguration, formatDateFull) => {
|
|
102
|
+
if (selectionConfiguration.type === CALENDAR_SELECTION_TYPE.single && selectionConfiguration.date) {
|
|
103
|
+
return formatDateFull(selectionConfiguration.date);
|
|
104
|
+
}
|
|
105
|
+
if (selectionConfiguration.type === CALENDAR_SELECTION_TYPE.range) {
|
|
106
|
+
if (selectionConfiguration.startDate && !selectionConfiguration.endDate) {
|
|
107
|
+
return formatDateFull(selectionConfiguration.startDate);
|
|
108
|
+
}
|
|
109
|
+
if (selectionConfiguration.startDate && selectionConfiguration.endDate) {
|
|
110
|
+
return `${formatDateFull(selectionConfiguration.startDate)} - ${formatDateFull(selectionConfiguration.endDate)}`;
|
|
111
|
+
}
|
|
112
|
+
}
|
|
113
|
+
return '';
|
|
114
|
+
};
|
|
115
|
+
|
|
116
|
+
/**
|
|
117
|
+
* Gets the correct value for the input field
|
|
118
|
+
* @param {Object} selectionConfiguration current selection configuration
|
|
119
|
+
* @param {Function} formatDate function supplied to format date
|
|
120
|
+
* @returns {String} date value
|
|
121
|
+
*/
|
|
122
|
+
getValue = (selectionConfiguration, formatDate) => {
|
|
123
|
+
if (selectionConfiguration.type === CALENDAR_SELECTION_TYPE.single && selectionConfiguration.date) {
|
|
124
|
+
return formatDate(selectionConfiguration.date);
|
|
125
|
+
}
|
|
126
|
+
if (selectionConfiguration.type === CALENDAR_SELECTION_TYPE.range) {
|
|
127
|
+
if (selectionConfiguration.startDate && !selectionConfiguration.endDate) {
|
|
128
|
+
return formatDate(selectionConfiguration.startDate);
|
|
129
|
+
}
|
|
130
|
+
if (selectionConfiguration.startDate && selectionConfiguration.endDate) {
|
|
131
|
+
return `${formatDate(selectionConfiguration.startDate)} - ${formatDate(selectionConfiguration.endDate)}`;
|
|
132
|
+
}
|
|
133
|
+
}
|
|
134
|
+
return '';
|
|
135
|
+
};
|
|
136
|
+
handleDateSelect = (startDate, endDate = null) => {
|
|
137
|
+
const {
|
|
138
|
+
maxDate,
|
|
139
|
+
minDate,
|
|
140
|
+
onClose,
|
|
141
|
+
onDateSelect,
|
|
142
|
+
selectionConfiguration
|
|
143
|
+
} = this.props;
|
|
144
|
+
|
|
145
|
+
// When the calendar is a single date we always want to close it when a date is selected
|
|
146
|
+
// or if its a range calendar we only want to close the calendar when a range is selected.
|
|
147
|
+
// If a custom onClose function is provided then we don't want to run the internal version.
|
|
148
|
+
if (selectionConfiguration && (selectionConfiguration.type === CALENDAR_SELECTION_TYPE.single || selectionConfiguration.type === CALENDAR_SELECTION_TYPE.range && endDate) && !onClose) {
|
|
149
|
+
this.onClose();
|
|
150
|
+
}
|
|
151
|
+
if (onDateSelect) {
|
|
152
|
+
const newStartDate = DateUtils.dateToBoundaries(startDate, DateUtils.startOfDay(minDate), DateUtils.startOfDay(maxDate));
|
|
153
|
+
const newEndDate = DateUtils.dateToBoundaries(endDate, DateUtils.startOfDay(minDate), DateUtils.startOfDay(maxDate));
|
|
154
|
+
if (selectionConfiguration && selectionConfiguration.type === CALENDAR_SELECTION_TYPE.range && selectionConfiguration.startDate && !selectionConfiguration.endDate && (DateUtils.isAfter(newEndDate, selectionConfiguration.startDate) || DateUtils.isSameDay(newEndDate, selectionConfiguration.startDate))) {
|
|
155
|
+
onDateSelect(selectionConfiguration.startDate, newEndDate);
|
|
156
|
+
} else {
|
|
157
|
+
onDateSelect(newStartDate);
|
|
158
|
+
}
|
|
159
|
+
}
|
|
160
|
+
};
|
|
161
|
+
render() {
|
|
162
|
+
const {
|
|
163
|
+
calendarComponent: Calendar,
|
|
164
|
+
changeMonthLabel,
|
|
165
|
+
closeButtonText,
|
|
166
|
+
dateModifiers,
|
|
167
|
+
daysOfWeek,
|
|
168
|
+
fixedWidth,
|
|
169
|
+
formatDate,
|
|
170
|
+
formatDateFull,
|
|
171
|
+
formatMonth,
|
|
172
|
+
getApplicationElement,
|
|
173
|
+
id,
|
|
174
|
+
initiallyFocusedDate,
|
|
175
|
+
inputComponent,
|
|
176
|
+
inputProps,
|
|
177
|
+
markOutsideDays,
|
|
178
|
+
markToday,
|
|
179
|
+
maxDate,
|
|
180
|
+
minDate,
|
|
181
|
+
nextMonthLabel,
|
|
182
|
+
onMonthChange,
|
|
183
|
+
previousMonthLabel,
|
|
184
|
+
renderTarget,
|
|
185
|
+
selectionConfiguration,
|
|
186
|
+
title,
|
|
187
|
+
valid,
|
|
188
|
+
weekStartsOn,
|
|
189
|
+
...rest
|
|
190
|
+
} = this.props;
|
|
191
|
+
|
|
192
|
+
// The following props are not used in render
|
|
193
|
+
delete rest.onDateSelect;
|
|
194
|
+
delete rest.onOpenChange;
|
|
195
|
+
delete rest.isOpen;
|
|
196
|
+
const input = inputComponent || /*#__PURE__*/_jsx("div", {
|
|
197
|
+
className: getClassName('bpk-datepicker__input'),
|
|
198
|
+
ref: this.inputRef,
|
|
199
|
+
children: /*#__PURE__*/_jsx(Input, {
|
|
200
|
+
id: id,
|
|
201
|
+
name: `${id}_input`,
|
|
202
|
+
value: this.getValue(selectionConfiguration, formatDate),
|
|
203
|
+
"aria-live": "assertive",
|
|
204
|
+
"aria-atomic": "true",
|
|
205
|
+
"aria-label": this.getLabel(selectionConfiguration, formatDateFull),
|
|
206
|
+
onChange: () => null,
|
|
207
|
+
onOpen: this.onOpen,
|
|
208
|
+
isOpen: this.state.isOpen,
|
|
209
|
+
valid: valid,
|
|
210
|
+
...inputProps
|
|
211
|
+
})
|
|
212
|
+
});
|
|
213
|
+
const calendarProps = {
|
|
214
|
+
id: `${id}-calendar`,
|
|
215
|
+
className: getClassName('bpk-datepicker__calendar'),
|
|
216
|
+
changeMonthLabel,
|
|
217
|
+
dateModifiers,
|
|
218
|
+
daysOfWeek,
|
|
219
|
+
formatDateFull,
|
|
220
|
+
formatMonth,
|
|
221
|
+
markOutsideDays,
|
|
222
|
+
markToday,
|
|
223
|
+
maxDate,
|
|
224
|
+
minDate,
|
|
225
|
+
nextMonthLabel,
|
|
226
|
+
onDateSelect: this.handleDateSelect,
|
|
227
|
+
onMonthChange,
|
|
228
|
+
previousMonthLabel,
|
|
229
|
+
weekStartsOn,
|
|
230
|
+
initiallyFocusedDate,
|
|
231
|
+
selectionConfiguration
|
|
232
|
+
};
|
|
233
|
+
return /*#__PURE__*/_jsx(BpkBreakpoint, {
|
|
234
|
+
query: BREAKPOINTS.MOBILE,
|
|
235
|
+
children: isMobile => isMobile ? /*#__PURE__*/_jsxs(_Fragment, {
|
|
236
|
+
children: [input, /*#__PURE__*/_jsx(BpkModal, {
|
|
237
|
+
id: `${id}-modal`,
|
|
238
|
+
renderTarget: renderTarget,
|
|
239
|
+
onClose: this.props.onClose || this.onClose,
|
|
240
|
+
isOpen: this.state.isOpen,
|
|
241
|
+
title: title,
|
|
242
|
+
closeLabel: closeButtonText,
|
|
243
|
+
getApplicationElement: getApplicationElement,
|
|
244
|
+
children: /*#__PURE__*/_jsx(Calendar, {
|
|
245
|
+
...calendarProps,
|
|
246
|
+
fixedWidth: false
|
|
247
|
+
})
|
|
248
|
+
})]
|
|
249
|
+
}) : /*#__PURE__*/_jsx(BpkPopover, {
|
|
250
|
+
id: `${id}-popover`,
|
|
251
|
+
target: input,
|
|
252
|
+
renderTarget: renderTarget,
|
|
253
|
+
onClose: this.props.onClose || this.onClose,
|
|
254
|
+
isOpen: this.state.isOpen,
|
|
255
|
+
label: title,
|
|
256
|
+
closeButtonText: closeButtonText,
|
|
257
|
+
tabIndex: 0,
|
|
258
|
+
...rest,
|
|
259
|
+
children: /*#__PURE__*/_jsx(Calendar, {
|
|
260
|
+
...calendarProps,
|
|
261
|
+
fixedWidth: fixedWidth
|
|
262
|
+
})
|
|
263
|
+
})
|
|
264
|
+
});
|
|
265
|
+
}
|
|
266
|
+
}
|
|
267
|
+
export default BpkDatepicker;
|
|
@@ -16,15 +16,8 @@
|
|
|
16
16
|
* limitations under the License.
|
|
17
17
|
*/
|
|
18
18
|
|
|
19
|
-
import { themeAttributes as calendarAttributes } from
|
|
20
|
-
import { themeAttributes as modalAttributes } from
|
|
19
|
+
import { themeAttributes as calendarAttributes } from "../../bpk-component-calendar";
|
|
20
|
+
import { themeAttributes as modalAttributes } from "../../bpk-component-modal";
|
|
21
21
|
// @ts-expect-error Untyped import. See `decisions/imports-ts-suppressions.md`.
|
|
22
|
-
import { themeAttributes as popoverAttributes } from
|
|
23
|
-
|
|
24
|
-
export default [
|
|
25
|
-
...calendarAttributes,
|
|
26
|
-
...popoverAttributes,
|
|
27
|
-
...modalAttributes,
|
|
28
|
-
].filter(
|
|
29
|
-
(attribute, index, attributes) => attributes.indexOf(attribute) === index,
|
|
30
|
-
);
|
|
22
|
+
import { themeAttributes as popoverAttributes } from "../../bpk-component-popover";
|
|
23
|
+
export default [...calendarAttributes, ...popoverAttributes, ...modalAttributes].filter((attribute, index, attributes) => attributes.indexOf(attribute) === index);
|
|
@@ -16,8 +16,7 @@
|
|
|
16
16
|
* limitations under the License.
|
|
17
17
|
*/
|
|
18
18
|
|
|
19
|
-
import BpkDescriptionList from
|
|
20
|
-
import BpkDescriptionTerm from
|
|
21
|
-
import BpkDescriptionDetails from
|
|
22
|
-
|
|
23
|
-
export { BpkDescriptionList, BpkDescriptionTerm, BpkDescriptionDetails };
|
|
19
|
+
import BpkDescriptionList from "./src/BpkDescriptionList";
|
|
20
|
+
import BpkDescriptionTerm from "./src/BpkDescriptionTerm";
|
|
21
|
+
import BpkDescriptionDetails from "./src/BpkDescriptionDetails";
|
|
22
|
+
export { BpkDescriptionList, BpkDescriptionTerm, BpkDescriptionDetails };
|
|
@@ -16,6 +16,5 @@
|
|
|
16
16
|
* limitations under the License.
|
|
17
17
|
*/
|
|
18
18
|
|
|
19
|
-
import buildComponent from
|
|
20
|
-
|
|
21
|
-
export default buildComponent('dd', 'bpk-description-list__details');
|
|
19
|
+
import buildComponent from "./ComponentFactory";
|
|
20
|
+
export default buildComponent('dd', 'bpk-description-list__details');
|
|
@@ -16,6 +16,5 @@
|
|
|
16
16
|
* limitations under the License.
|
|
17
17
|
*/
|
|
18
18
|
|
|
19
|
-
import buildComponent from
|
|
20
|
-
|
|
21
|
-
export default buildComponent('dl', 'bpk-description-list');
|
|
19
|
+
import buildComponent from "./ComponentFactory";
|
|
20
|
+
export default buildComponent('dl', 'bpk-description-list');
|
|
@@ -16,6 +16,5 @@
|
|
|
16
16
|
* limitations under the License.
|
|
17
17
|
*/
|
|
18
18
|
|
|
19
|
-
import buildComponent from
|
|
20
|
-
|
|
21
|
-
export default buildComponent('dt', 'bpk-description-list__term');
|
|
19
|
+
import buildComponent from "./ComponentFactory";
|
|
20
|
+
export default buildComponent('dt', 'bpk-description-list__term');
|
|
@@ -17,38 +17,33 @@
|
|
|
17
17
|
*/
|
|
18
18
|
|
|
19
19
|
import PropTypes from 'prop-types';
|
|
20
|
-
|
|
21
|
-
import
|
|
22
|
-
|
|
23
|
-
import STYLES from './BpkDescriptionList.module.scss';
|
|
24
|
-
|
|
20
|
+
import { cssModules } from "../../bpk-react-utils";
|
|
21
|
+
import STYLES from "./BpkDescriptionList.module.css";
|
|
22
|
+
import { jsx as _jsx } from "react/jsx-runtime";
|
|
25
23
|
const getClassName = cssModules(STYLES);
|
|
26
|
-
|
|
27
24
|
const buildComponent = (TagName, baseClassName) => {
|
|
28
|
-
const Component = ({
|
|
25
|
+
const Component = ({
|
|
26
|
+
children,
|
|
27
|
+
className,
|
|
28
|
+
...rest
|
|
29
|
+
}) => {
|
|
29
30
|
const classNames = [getClassName(baseClassName)];
|
|
30
|
-
|
|
31
31
|
if (className) {
|
|
32
32
|
classNames.push(className);
|
|
33
33
|
}
|
|
34
|
-
|
|
35
|
-
|
|
36
|
-
|
|
37
|
-
|
|
38
|
-
|
|
39
|
-
);
|
|
34
|
+
return /*#__PURE__*/_jsx(TagName, {
|
|
35
|
+
className: classNames.join(' '),
|
|
36
|
+
...rest,
|
|
37
|
+
children: children
|
|
38
|
+
});
|
|
40
39
|
};
|
|
41
|
-
|
|
42
40
|
Component.propTypes = {
|
|
43
41
|
children: PropTypes.node.isRequired,
|
|
44
|
-
className: PropTypes.string
|
|
42
|
+
className: PropTypes.string
|
|
45
43
|
};
|
|
46
|
-
|
|
47
44
|
Component.defaultProps = {
|
|
48
|
-
className: null
|
|
45
|
+
className: null
|
|
49
46
|
};
|
|
50
|
-
|
|
51
47
|
return Component;
|
|
52
48
|
};
|
|
53
|
-
|
|
54
|
-
export default buildComponent;
|
|
49
|
+
export default buildComponent;
|
|
@@ -16,9 +16,7 @@
|
|
|
16
16
|
* limitations under the License.
|
|
17
17
|
*/
|
|
18
18
|
|
|
19
|
-
|
|
20
|
-
|
|
21
|
-
|
|
22
|
-
|
|
23
|
-
'bannerAlertErrorColor',
|
|
24
|
-
];
|
|
19
|
+
import BpkDialog from "./src/BpkDialog";
|
|
20
|
+
import { HEADER_ICON_TYPES } from "./src/common-types";
|
|
21
|
+
export default BpkDialog;
|
|
22
|
+
export { HEADER_ICON_TYPES };
|
|
@@ -0,0 +1,63 @@
|
|
|
1
|
+
/*
|
|
2
|
+
* Backpack - Skyscanner's Design System
|
|
3
|
+
*
|
|
4
|
+
* Copyright 2016 Skyscanner Ltd
|
|
5
|
+
*
|
|
6
|
+
* Licensed under the Apache License, Version 2.0 (the "License");
|
|
7
|
+
* you may not use this file except in compliance with the License.
|
|
8
|
+
* You may obtain a copy of the License at
|
|
9
|
+
*
|
|
10
|
+
* http://www.apache.org/licenses/LICENSE-2.0
|
|
11
|
+
*
|
|
12
|
+
* Unless required by applicable law or agreed to in writing, software
|
|
13
|
+
* distributed under the License is distributed on an "AS IS" BASIS,
|
|
14
|
+
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
|
15
|
+
* See the License for the specific language governing permissions and
|
|
16
|
+
* limitations under the License.
|
|
17
|
+
*/
|
|
18
|
+
|
|
19
|
+
import { cssModules, Portal } from "../../bpk-react-utils";
|
|
20
|
+
// @ts-expect-error Untyped import. See `decisions/imports-ts-suppressions.md`.
|
|
21
|
+
import BpkCloseButton from "../../bpk-component-close-button";
|
|
22
|
+
import BpkDialogInner from "./BpkDialogInner";
|
|
23
|
+
import { HEADER_ICON_TYPES } from "./common-types";
|
|
24
|
+
import STYLES from "./BpkDialog.module.css";
|
|
25
|
+
import { jsx as _jsx } from "react/jsx-runtime";
|
|
26
|
+
import { jsxs as _jsxs } from "react/jsx-runtime";
|
|
27
|
+
const getClassName = cssModules(STYLES);
|
|
28
|
+
const BpkDialog = ({
|
|
29
|
+
children,
|
|
30
|
+
closeLabel = '',
|
|
31
|
+
dismissible = true,
|
|
32
|
+
headerIcon = null,
|
|
33
|
+
headerIconType = HEADER_ICON_TYPES.primary,
|
|
34
|
+
isOpen,
|
|
35
|
+
onClose = () => {},
|
|
36
|
+
renderTarget = () => null,
|
|
37
|
+
...rest
|
|
38
|
+
}) => {
|
|
39
|
+
const headerIconClassNames = getClassName('bpk-dialog__icon', `bpk-dialog__icon--${headerIconType}`);
|
|
40
|
+
const closeButtonClassNames = getClassName('bpk-dialog__close-button');
|
|
41
|
+
return /*#__PURE__*/_jsx(Portal, {
|
|
42
|
+
isOpen: isOpen,
|
|
43
|
+
onClose: onClose,
|
|
44
|
+
renderTarget: renderTarget,
|
|
45
|
+
closeOnEscPressed: dismissible,
|
|
46
|
+
children: /*#__PURE__*/_jsxs(BpkDialogInner, {
|
|
47
|
+
onClose: onClose,
|
|
48
|
+
closeOnScrimClick: dismissible,
|
|
49
|
+
containerClassName: getClassName('bpk-dialog__container'),
|
|
50
|
+
contentClassName: headerIcon ? getClassName('bpk-dialog--with-icon') : undefined,
|
|
51
|
+
...rest,
|
|
52
|
+
children: [headerIcon && /*#__PURE__*/_jsx("div", {
|
|
53
|
+
className: headerIconClassNames,
|
|
54
|
+
children: headerIcon
|
|
55
|
+
}), dismissible && /*#__PURE__*/_jsx(BpkCloseButton, {
|
|
56
|
+
className: closeButtonClassNames,
|
|
57
|
+
label: closeLabel,
|
|
58
|
+
onClick: onClose
|
|
59
|
+
}), children]
|
|
60
|
+
})
|
|
61
|
+
});
|
|
62
|
+
};
|
|
63
|
+
export default BpkDialog;
|