@skyscanner/backpack-web 42.6.0 → 42.7.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/bpk-component-aria-live/src/BpkAriaLive.story-helpers.d.ts +11 -0
- package/bpk-component-aria-live/src/BpkAriaLive.story-helpers.js +48 -0
- package/bpk-component-bubble/src/BpkBubble.module.css +1 -1
- package/bpk-component-layout/src/commonProps.d.ts +9 -3
- package/bpk-component-layout/src/tokenUtils.js +22 -6
- package/bpk-component-layout/src/tokens.d.ts +17 -3
- package/bpk-component-layout/src/tokens.js +19 -3
- package/bpk-component-spinner/src/SpinnerLayout.story-helpers.d.ts +12 -0
- package/bpk-component-spinner/src/SpinnerLayout.story-helpers.js +47 -0
- package/bpk-component-spinner/src/SpinnerLayout.story-helpers.module.css +18 -0
- package/bpk-component-text/src/BpkText.module.css +1 -1
- package/bpk-stylesheets/base.css +1 -1
- package/package.json +2 -2
|
@@ -0,0 +1,11 @@
|
|
|
1
|
+
import type { ReactElement } from 'react';
|
|
2
|
+
type AriaLiveDemoProps = {
|
|
3
|
+
preamble?: ReactElement | null;
|
|
4
|
+
children: ReactElement;
|
|
5
|
+
className?: string | null;
|
|
6
|
+
style?: {};
|
|
7
|
+
visible?: Boolean;
|
|
8
|
+
[rest: string]: any;
|
|
9
|
+
};
|
|
10
|
+
declare const AriaLiveDemo: ({ children, className, preamble, style, visible, ...rest }: AriaLiveDemoProps) => import("react/jsx-runtime").JSX.Element;
|
|
11
|
+
export default AriaLiveDemo;
|
|
@@ -0,0 +1,48 @@
|
|
|
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 { ARIA_LIVE_POLITENESS_SETTINGS } from '..';
|
|
20
|
+
import { cssModules } from "../../bpk-react-utils";
|
|
21
|
+
import BpkAriaLive from "./BpkAriaLive";
|
|
22
|
+
import STYLES from "./BpkAriaLive.stories.module.css";
|
|
23
|
+
import { jsx as _jsx, jsxs as _jsxs } from "react/jsx-runtime";
|
|
24
|
+
const getClassName = cssModules(STYLES);
|
|
25
|
+
const AriaLiveDemo = ({
|
|
26
|
+
children,
|
|
27
|
+
className = null,
|
|
28
|
+
preamble = null,
|
|
29
|
+
style = undefined,
|
|
30
|
+
visible = false,
|
|
31
|
+
...rest
|
|
32
|
+
}) => /*#__PURE__*/_jsxs("div", {
|
|
33
|
+
className: getClassName('bpk-storybook-aria-live-demo', className),
|
|
34
|
+
style: style,
|
|
35
|
+
children: [/*#__PURE__*/_jsx("p", {
|
|
36
|
+
children: /*#__PURE__*/_jsx("strong", {
|
|
37
|
+
children: "ARIA live region:"
|
|
38
|
+
})
|
|
39
|
+
}), /*#__PURE__*/_jsx("p", {
|
|
40
|
+
children: visible ? 'This content is relevant to everyone, not just assistive technologies, so it is permanently visible.' : 'This would usually be visually hidden, and only visible to assistive technologies. It is visible here for demo purposes.'
|
|
41
|
+
}), preamble, /*#__PURE__*/_jsx(BpkAriaLive, {
|
|
42
|
+
...rest,
|
|
43
|
+
visible: true,
|
|
44
|
+
politenessSetting: ARIA_LIVE_POLITENESS_SETTINGS.assertive,
|
|
45
|
+
children: children
|
|
46
|
+
})]
|
|
47
|
+
});
|
|
48
|
+
export default AriaLiveDemo;
|
|
@@ -15,4 +15,4 @@
|
|
|
15
15
|
* See the License for the specific language governing permissions and
|
|
16
16
|
* limitations under the License.
|
|
17
17
|
*/
|
|
18
|
-
.bpk-bubble{position:relative;display:inline-flex;width:auto;height:1.25rem;padding:0 .5rem;flex-direction:column;justify-content:center;border-radius:.25rem;background-color:#e70866;font-family:var(--bpk-larken-font-stack, "Larken", "Noto Sans Arabic", "Noto Serif Hebrew", "Noto Serif", "Noto Serif Devanagari", "Noto Serif Thai", "Noto Serif
|
|
18
|
+
.bpk-bubble{position:relative;display:inline-flex;width:auto;height:1.25rem;padding:0 .5rem;flex-direction:column;justify-content:center;border-radius:.25rem;background-color:#e70866;font-family:var(--bpk-larken-font-stack, "Larken", "Noto Sans Arabic", "Noto Serif Hebrew", "Noto Serif", "Noto Serif Devanagari", "Noto Serif Thai", "Noto Serif TC", "Noto Serif JP", "Noto Serif KR", "Noto Serif SC", sans-serif);text-align:center;white-space:nowrap;font-size:.75rem;line-height:1rem;font-weight:400}.bpk-bubble__arrow{position:absolute;bottom:-5px;left:50%;transform:translateX(-50%);color:#e70866}
|
|
@@ -1,6 +1,6 @@
|
|
|
1
|
-
import type { AriaRole, KeyboardEventHandler, MouseEventHandler } from 'react';
|
|
1
|
+
import type { AriaAttributes, AriaRole, KeyboardEventHandler, MouseEventHandler } from 'react';
|
|
2
2
|
import type { BpkLayoutBackgroundColor } from './backgroundColors';
|
|
3
|
-
import type { BpkSpacingValue, BpkSizeValue, BpkPositionValue, BpkResponsiveValue } from './tokens';
|
|
3
|
+
import type { BpkSpacingValue, BpkSizeValue, BpkPositionValue, BpkPositionKeyword, BpkOverflowValue, BpkZIndexValue, BpkResponsiveValue } from './tokens';
|
|
4
4
|
import type { TextColor, TextStyle } from '../../bpk-component-text';
|
|
5
5
|
/**
|
|
6
6
|
* Common spacing-related props shared by all Backpack layout components
|
|
@@ -46,14 +46,20 @@ export interface BpkSpacingProps {
|
|
|
46
46
|
* container patterns (e.g. clickable cards, landmark regions).
|
|
47
47
|
* - BpkBox additionally exposes onFocus and onBlur on its own props type.
|
|
48
48
|
*/
|
|
49
|
-
export interface BpkCommonLayoutProps extends BpkSpacingProps {
|
|
49
|
+
export interface BpkCommonLayoutProps extends BpkSpacingProps, AriaAttributes {
|
|
50
50
|
className?: never;
|
|
51
51
|
style?: never;
|
|
52
|
+
id?: string;
|
|
52
53
|
tabIndex?: number;
|
|
53
54
|
role?: AriaRole;
|
|
54
55
|
onClick?: MouseEventHandler<HTMLElement>;
|
|
55
56
|
onKeyDown?: KeyboardEventHandler<HTMLElement>;
|
|
56
57
|
textStyle?: BpkResponsiveValue<TextStyle>;
|
|
58
|
+
position?: BpkResponsiveValue<BpkPositionKeyword>;
|
|
59
|
+
overflow?: BpkResponsiveValue<BpkOverflowValue>;
|
|
60
|
+
overflowX?: BpkResponsiveValue<BpkOverflowValue>;
|
|
61
|
+
overflowY?: BpkResponsiveValue<BpkOverflowValue>;
|
|
62
|
+
zIndex?: BpkZIndexValue;
|
|
57
63
|
'data-testid'?: string;
|
|
58
64
|
'data-cy'?: string;
|
|
59
65
|
color?: TextColor;
|
|
@@ -41,7 +41,9 @@ export const BPK_RESPONSIVE_PROP_GROUPS_BY_COMPONENT = {
|
|
|
41
41
|
// Flex container props
|
|
42
42
|
'flexDirection', 'flexWrap', 'justifyContent', 'alignItems', 'alignContent',
|
|
43
43
|
// Grid container props
|
|
44
|
-
'gridTemplateColumns', 'gridTemplateRows', 'gridTemplateAreas', 'gridAutoFlow', 'gridAutoRows', 'gridAutoColumns'
|
|
44
|
+
'gridTemplateColumns', 'gridTemplateRows', 'gridTemplateAreas', 'gridAutoFlow', 'gridAutoRows', 'gridAutoColumns',
|
|
45
|
+
// Position keyword and overflow (from BpkCommonLayoutProps)
|
|
46
|
+
'position', 'overflow', 'overflowX', 'overflowY'],
|
|
45
47
|
item: [
|
|
46
48
|
// Flex item props
|
|
47
49
|
'flex', 'flexGrow', 'flexShrink', 'flexBasis', 'order', 'alignSelf', 'justifySelf',
|
|
@@ -50,22 +52,28 @@ export const BPK_RESPONSIVE_PROP_GROUPS_BY_COMPONENT = {
|
|
|
50
52
|
},
|
|
51
53
|
// Note: BpkFlex maps its public API props to these Chakra keys.
|
|
52
54
|
BpkFlex: {
|
|
53
|
-
container: ['textStyle', 'flexDirection', 'justifyContent', 'alignItems', 'flexWrap'
|
|
55
|
+
container: ['textStyle', 'flexDirection', 'justifyContent', 'alignItems', 'flexWrap',
|
|
56
|
+
// Position keyword and overflow (from BpkCommonLayoutProps)
|
|
57
|
+
'position', 'overflow', 'overflowX', 'overflowY'],
|
|
54
58
|
item: ['flexGrow', 'flexShrink', 'flexBasis']
|
|
55
59
|
},
|
|
56
60
|
// Note: BpkGrid maps its public API props to these Chakra keys.
|
|
57
61
|
BpkGrid: {
|
|
58
|
-
container: ['textStyle', 'justifyContent', 'alignItems', 'gridTemplateColumns', 'gridTemplateRows', 'gridTemplateAreas', 'gridAutoFlow', 'gridAutoRows', 'gridAutoColumns'
|
|
62
|
+
container: ['textStyle', 'justifyContent', 'alignItems', 'gridTemplateColumns', 'gridTemplateRows', 'gridTemplateAreas', 'gridAutoFlow', 'gridAutoRows', 'gridAutoColumns',
|
|
63
|
+
// Position keyword and overflow (from BpkCommonLayoutProps)
|
|
64
|
+
'position', 'overflow', 'overflowX', 'overflowY'],
|
|
59
65
|
item: [
|
|
60
66
|
// Used when placing the grid itself within a parent grid.
|
|
61
67
|
'gridColumn', 'gridRow']
|
|
62
68
|
},
|
|
63
69
|
BpkGridItem: {
|
|
64
|
-
container: ['textStyle']
|
|
70
|
+
container: ['textStyle', 'position', 'overflow', 'overflowX', 'overflowY']
|
|
65
71
|
},
|
|
66
72
|
// Note: BpkStack uses Chakra Stack option prop names directly.
|
|
67
73
|
BpkStack: {
|
|
68
|
-
container: ['textStyle', ...StackOptionKeys
|
|
74
|
+
container: ['textStyle', ...StackOptionKeys,
|
|
75
|
+
// Position keyword and overflow (from BpkCommonLayoutProps)
|
|
76
|
+
'position', 'overflow', 'overflowX', 'overflowY']
|
|
69
77
|
}
|
|
70
78
|
};
|
|
71
79
|
export const BPK_RESPONSIVE_PROP_KEYS_BY_COMPONENT = {
|
|
@@ -101,7 +109,15 @@ function filterToAllowlist(props, allowlist) {
|
|
|
101
109
|
export function processBpkComponentProps(props, options) {
|
|
102
110
|
const processed = processBpkProps(props);
|
|
103
111
|
const allowlist = BPK_RESPONSIVE_PROP_KEYS_BY_COMPONENT[options.component];
|
|
104
|
-
|
|
112
|
+
// When responsiveProps is provided (e.g. BpkFlex maps direction→flexDirection),
|
|
113
|
+
// merge it with any allowlisted props already in `processed` (e.g. position/overflow
|
|
114
|
+
// that come in via ...props and are NOT included in responsiveProps).
|
|
115
|
+
// responsiveProps takes precedence so that explicit prop-name mappings always win.
|
|
116
|
+
const processedAllowlisted = filterToAllowlist(processed, allowlist);
|
|
117
|
+
const responsiveSource = options.responsiveProps ? {
|
|
118
|
+
...processedAllowlisted,
|
|
119
|
+
...filterToAllowlist(options.responsiveProps, allowlist)
|
|
120
|
+
} : processedAllowlisted;
|
|
105
121
|
if (Object.keys(responsiveSource).length === 0) {
|
|
106
122
|
return processed;
|
|
107
123
|
}
|
|
@@ -47,10 +47,24 @@ export type BpkBreakpointValue = BpkBreakpointToken;
|
|
|
47
47
|
*/
|
|
48
48
|
export type BpkSizeValue = `${number}rem` | `${number}%` | 'auto' | 'full' | 'fit-content';
|
|
49
49
|
/**
|
|
50
|
-
* Helper type for position props that can use rem or
|
|
51
|
-
*
|
|
50
|
+
* Helper type for position props that can use rem, percentages, or bare zero.
|
|
51
|
+
* CSS allows `0` without a unit; `'0'` is therefore an explicit allowed value.
|
|
52
|
+
* We intentionally do not allow other semantic values like 'auto' here.
|
|
52
53
|
*/
|
|
53
|
-
export type BpkPositionValue = `${number}rem` | `${number}
|
|
54
|
+
export type BpkPositionValue = `${number}rem` | `${number}%` | '0';
|
|
55
|
+
/**
|
|
56
|
+
* CSS `position` property keyword values.
|
|
57
|
+
*/
|
|
58
|
+
export type BpkPositionKeyword = 'static' | 'relative' | 'absolute' | 'fixed' | 'sticky';
|
|
59
|
+
/**
|
|
60
|
+
* CSS `overflow` property keyword values.
|
|
61
|
+
*/
|
|
62
|
+
export type BpkOverflowValue = 'visible' | 'hidden' | 'scroll' | 'auto' | 'clip';
|
|
63
|
+
/**
|
|
64
|
+
* CSS `z-index` values. Numeric values only; 'auto' is also permitted.
|
|
65
|
+
* Avoid magic numbers — prefer a shared z-index scale in your app.
|
|
66
|
+
*/
|
|
67
|
+
export type BpkZIndexValue = number | 'auto';
|
|
54
68
|
/**
|
|
55
69
|
* Helper type for flex-basis prop that can use rem, percentages or semantic values.
|
|
56
70
|
* Excludes 'px' values to enforce design system constraints.
|
|
@@ -71,8 +71,22 @@ export const BpkBreakpointToChakraKey = {
|
|
|
71
71
|
*/
|
|
72
72
|
|
|
73
73
|
/**
|
|
74
|
-
* Helper type for position props that can use rem or
|
|
75
|
-
*
|
|
74
|
+
* Helper type for position props that can use rem, percentages, or bare zero.
|
|
75
|
+
* CSS allows `0` without a unit; `'0'` is therefore an explicit allowed value.
|
|
76
|
+
* We intentionally do not allow other semantic values like 'auto' here.
|
|
77
|
+
*/
|
|
78
|
+
|
|
79
|
+
/**
|
|
80
|
+
* CSS `position` property keyword values.
|
|
81
|
+
*/
|
|
82
|
+
|
|
83
|
+
/**
|
|
84
|
+
* CSS `overflow` property keyword values.
|
|
85
|
+
*/
|
|
86
|
+
|
|
87
|
+
/**
|
|
88
|
+
* CSS `z-index` values. Numeric values only; 'auto' is also permitted.
|
|
89
|
+
* Avoid magic numbers — prefer a shared z-index scale in your app.
|
|
76
90
|
*/
|
|
77
91
|
|
|
78
92
|
/**
|
|
@@ -131,7 +145,9 @@ export function isValidSizeValue(value) {
|
|
|
131
145
|
* @returns {boolean} True if the value is a valid rem or percentage
|
|
132
146
|
*/
|
|
133
147
|
export function isValidPositionValue(value) {
|
|
134
|
-
return
|
|
148
|
+
return value === '0' ||
|
|
149
|
+
// bare zero — valid CSS without a unit
|
|
150
|
+
/^-?\d+(\.\d+)?rem$/.test(value) ||
|
|
135
151
|
// rem values
|
|
136
152
|
isPercentage(value) // percentage values
|
|
137
153
|
;
|
|
@@ -0,0 +1,12 @@
|
|
|
1
|
+
import PropTypes from 'prop-types';
|
|
2
|
+
import type { ReactElement } from 'react';
|
|
3
|
+
type Props = {
|
|
4
|
+
children: Array<ReactElement<any, any>> | ReactElement<any, any>;
|
|
5
|
+
};
|
|
6
|
+
declare const SpinnerLayout: {
|
|
7
|
+
(props: Props): import("react/jsx-runtime").JSX.Element;
|
|
8
|
+
propTypes: {
|
|
9
|
+
children: PropTypes.Validator<NonNullable<PropTypes.ReactNodeLike>>;
|
|
10
|
+
};
|
|
11
|
+
};
|
|
12
|
+
export default SpinnerLayout;
|
|
@@ -0,0 +1,47 @@
|
|
|
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 PropTypes from 'prop-types';
|
|
20
|
+
import { Children } from 'react';
|
|
21
|
+
import { cssModules } from "../../bpk-react-utils";
|
|
22
|
+
import SPINNER_TYPES from "./spinnerTypes";
|
|
23
|
+
import STYLES from "./SpinnerLayout.story-helpers.module.css";
|
|
24
|
+
import { jsx as _jsx } from "react/jsx-runtime";
|
|
25
|
+
const getClassName = cssModules(STYLES);
|
|
26
|
+
const SpinnerLayout = props => {
|
|
27
|
+
const {
|
|
28
|
+
children
|
|
29
|
+
} = props;
|
|
30
|
+
return /*#__PURE__*/_jsx("div", {
|
|
31
|
+
className: getClassName('bpk-spinner-layout'),
|
|
32
|
+
children: Children.map(children, child => {
|
|
33
|
+
const classNames = [getClassName('bpk-spinner-layout__spinner')];
|
|
34
|
+
if (child.props.type === SPINNER_TYPES.light) {
|
|
35
|
+
classNames.push(getClassName('bpk-spinner-layout__spinner--light'));
|
|
36
|
+
}
|
|
37
|
+
return /*#__PURE__*/_jsx("div", {
|
|
38
|
+
className: classNames.join(' '),
|
|
39
|
+
children: child
|
|
40
|
+
});
|
|
41
|
+
})
|
|
42
|
+
});
|
|
43
|
+
};
|
|
44
|
+
SpinnerLayout.propTypes = {
|
|
45
|
+
children: PropTypes.node.isRequired
|
|
46
|
+
};
|
|
47
|
+
export default SpinnerLayout;
|
|
@@ -0,0 +1,18 @@
|
|
|
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
|
+
.bpk-spinner-layout{display:flex;flex-direction:column}.bpk-spinner-layout__spinner{display:flex;padding:1.5rem;justify-content:center}.bpk-spinner-layout__spinner--light{background-color:#05203c;border-radius:.25rem}
|
|
@@ -15,4 +15,4 @@
|
|
|
15
15
|
* See the License for the specific language governing permissions and
|
|
16
16
|
* limitations under the License.
|
|
17
17
|
*/
|
|
18
|
-
.bpk-text{margin:0}.bpk-text--xs{font-size:.75rem;line-height:1rem;font-weight:400}.bpk-text--sm{font-size:.875rem;line-height:1.25rem;font-weight:400}.bpk-text--base{font-size:1rem;line-height:1.5rem;font-weight:400}.bpk-text--lg{font-size:1.25rem;line-height:1.75rem;font-weight:400}.bpk-text--xl{font-size:1.5rem;line-height:2rem;font-weight:400}.bpk-text--xxl{font-size:2rem;line-height:2.5rem;font-weight:700}.bpk-text--xxxl{font-size:2.5rem;line-height:3rem;font-weight:700}.bpk-text--xxxxl{font-size:3rem;line-height:3.5rem;font-weight:700;letter-spacing:-0.02em}.bpk-text--xxxxxl{font-size:4rem;line-height:4rem;font-weight:700;letter-spacing:-0.02em}.bpk-text--caption{font-size:.75rem;line-height:1rem;font-weight:400}.bpk-text--footnote{font-size:.875rem;line-height:1.25rem;font-weight:400}.bpk-text--label-1{font-size:1rem;line-height:1.5rem;font-weight:700}.bpk-text--label-2{font-size:.875rem;line-height:1.25rem;font-weight:700}.bpk-text--label-3{font-size:.75rem;line-height:1rem;font-weight:700}.bpk-text--body-default{font-size:1rem;line-height:1.5rem;font-weight:400}.bpk-text--body-longform{font-size:1.25rem;line-height:1.75rem;font-weight:400}.bpk-text--subheading{font-size:1.5rem;line-height:2rem;font-weight:400}.bpk-text--heading-1{font-size:2.5rem;line-height:3rem;font-weight:700}.bpk-text--heading-2{font-size:2rem;line-height:2.5rem;font-weight:700}.bpk-text--heading-3{font-size:1.5rem;line-height:1.75rem;font-weight:700}.bpk-text--heading-4{font-size:1.25rem;line-height:1.5rem;font-weight:700}.bpk-text--heading-5{font-size:1rem;line-height:1.25rem;font-weight:700}.bpk-text--hero-1{font-size:7.5rem;line-height:7.5rem;font-weight:900;letter-spacing:-0.04em}.bpk-text--hero-2{font-size:6rem;line-height:6rem;font-weight:900;letter-spacing:-0.04em}.bpk-text--hero-3{font-size:4.75rem;line-height:4.75rem;font-weight:900;letter-spacing:-0.04em}.bpk-text--hero-4{font-size:4rem;line-height:4rem;font-weight:900;letter-spacing:-0.04em}.bpk-text--hero-5{font-size:3rem;line-height:3rem;font-weight:900;letter-spacing:-0.04em}.bpk-text--hero-6{font-size:2.5rem;line-height:2.5rem;font-weight:900;letter-spacing:-0.04em}.bpk-text--editorial-1{font-family:var(--bpk-larken-font-stack, "Larken", "Noto Sans Arabic", "Noto Serif Hebrew", "Noto Serif", "Noto Serif Devanagari", "Noto Serif Thai", "Noto Serif
|
|
18
|
+
.bpk-text{margin:0}.bpk-text--xs{font-size:.75rem;line-height:1rem;font-weight:400}.bpk-text--sm{font-size:.875rem;line-height:1.25rem;font-weight:400}.bpk-text--base{font-size:1rem;line-height:1.5rem;font-weight:400}.bpk-text--lg{font-size:1.25rem;line-height:1.75rem;font-weight:400}.bpk-text--xl{font-size:1.5rem;line-height:2rem;font-weight:400}.bpk-text--xxl{font-size:2rem;line-height:2.5rem;font-weight:700}.bpk-text--xxxl{font-size:2.5rem;line-height:3rem;font-weight:700}.bpk-text--xxxxl{font-size:3rem;line-height:3.5rem;font-weight:700;letter-spacing:-0.02em}.bpk-text--xxxxxl{font-size:4rem;line-height:4rem;font-weight:700;letter-spacing:-0.02em}.bpk-text--caption{font-size:.75rem;line-height:1rem;font-weight:400}.bpk-text--footnote{font-size:.875rem;line-height:1.25rem;font-weight:400}.bpk-text--label-1{font-size:1rem;line-height:1.5rem;font-weight:700}.bpk-text--label-2{font-size:.875rem;line-height:1.25rem;font-weight:700}.bpk-text--label-3{font-size:.75rem;line-height:1rem;font-weight:700}.bpk-text--body-default{font-size:1rem;line-height:1.5rem;font-weight:400}.bpk-text--body-longform{font-size:1.25rem;line-height:1.75rem;font-weight:400}.bpk-text--subheading{font-size:1.5rem;line-height:2rem;font-weight:400}.bpk-text--heading-1{font-size:2.5rem;line-height:3rem;font-weight:700}.bpk-text--heading-2{font-size:2rem;line-height:2.5rem;font-weight:700}.bpk-text--heading-3{font-size:1.5rem;line-height:1.75rem;font-weight:700}.bpk-text--heading-4{font-size:1.25rem;line-height:1.5rem;font-weight:700}.bpk-text--heading-5{font-size:1rem;line-height:1.25rem;font-weight:700}.bpk-text--hero-1{font-size:7.5rem;line-height:7.5rem;font-weight:900;letter-spacing:-0.04em}.bpk-text--hero-2{font-size:6rem;line-height:6rem;font-weight:900;letter-spacing:-0.04em}.bpk-text--hero-3{font-size:4.75rem;line-height:4.75rem;font-weight:900;letter-spacing:-0.04em}.bpk-text--hero-4{font-size:4rem;line-height:4rem;font-weight:900;letter-spacing:-0.04em}.bpk-text--hero-5{font-size:3rem;line-height:3rem;font-weight:900;letter-spacing:-0.04em}.bpk-text--hero-6{font-size:2.5rem;line-height:2.5rem;font-weight:900;letter-spacing:-0.04em}.bpk-text--editorial-1{font-family:var(--bpk-larken-font-stack, "Larken", "Noto Sans Arabic", "Noto Serif Hebrew", "Noto Serif", "Noto Serif Devanagari", "Noto Serif Thai", "Noto Serif TC", "Noto Serif JP", "Noto Serif KR", "Noto Serif SC", sans-serif);font-size:3rem;line-height:3.5rem;font-weight:300}.bpk-text--editorial-2{font-family:var(--bpk-larken-font-stack, "Larken", "Noto Sans Arabic", "Noto Serif Hebrew", "Noto Serif", "Noto Serif Devanagari", "Noto Serif Thai", "Noto Serif TC", "Noto Serif JP", "Noto Serif KR", "Noto Serif SC", sans-serif);font-size:2rem;line-height:2.5rem;font-weight:300}.bpk-text--editorial-3{font-family:var(--bpk-larken-font-stack, "Larken", "Noto Sans Arabic", "Noto Serif Hebrew", "Noto Serif", "Noto Serif Devanagari", "Noto Serif Thai", "Noto Serif TC", "Noto Serif JP", "Noto Serif KR", "Noto Serif SC", sans-serif);font-size:1.25rem;line-height:1.75rem;font-weight:400}.bpk-text.bpk-text--text-disabled{color:rgba(0,0,0,.2)}.bpk-text.bpk-text--text-disabled-on-dark{color:hsla(0,0%,100%,.5)}.bpk-text.bpk-text--text-error{color:#e70866}.bpk-text.bpk-text--text-hero{color:#0062e3}.bpk-text.bpk-text--text-link{color:#0062e3}.bpk-text.bpk-text--text-on-dark{color:#fff}.bpk-text.bpk-text--text-on-light{color:#161616}.bpk-text.bpk-text--text-primary{color:#161616}.bpk-text.bpk-text--text-primary-inverse{color:#fff}.bpk-text.bpk-text--text-secondary{color:#626971}.bpk-text.bpk-text--text-success{color:#0c838a}
|
package/bpk-stylesheets/base.css
CHANGED
|
@@ -16,4 +16,4 @@
|
|
|
16
16
|
* See the License for the specific language governing permissions and
|
|
17
17
|
* limitations under the License.
|
|
18
18
|
*
|
|
19
|
-
*//*! normalize.css v4.1.1 | MIT License | github.com/necolas/normalize.css */html{font-family:sans-serif;line-height:1.15;-ms-text-size-adjust:100%;-webkit-text-size-adjust:100%}body{margin:0}article,aside,details,figcaption,figure,footer,header,main,menu,nav,section,summary{display:block}audio,canvas,progress,video{display:inline-block}audio:not([controls]){display:none;height:0}progress{vertical-align:baseline}template,[hidden]{display:none}a{background-color:rgba(0,0,0,0);-webkit-text-decoration-skip:objects}a:active,a:hover{outline-width:0}abbr[title]{border-bottom:none;text-decoration:underline;text-decoration:underline dotted}b,strong{font-weight:inherit}b,strong{font-weight:bolder}dfn{font-style:italic}h1{font-size:2em;margin:.67em 0}mark{background-color:#ff0;color:#000}small{font-size:80%}sub,sup{font-size:75%;line-height:0;position:relative;vertical-align:baseline}sub{bottom:-0.25em}sup{top:-0.5em}img{border-style:none}svg:not(:root){overflow:hidden}code,kbd,pre,samp{font-family:monospace,monospace;font-size:1em}figure{margin:1em 40px}hr{box-sizing:content-box;height:0;overflow:visible}button,input,optgroup,select,textarea{font:inherit;margin:0}optgroup{font-weight:bold}button,input{overflow:visible}button,select{text-transform:none}button,html [type=button],[type=reset],[type=submit]{-webkit-appearance:button}button::-moz-focus-inner,[type=button]::-moz-focus-inner,[type=reset]::-moz-focus-inner,[type=submit]::-moz-focus-inner{border-style:none;padding:0}button:-moz-focusring,[type=button]:-moz-focusring,[type=reset]:-moz-focusring,[type=submit]:-moz-focusring{outline:1px dotted ButtonText}fieldset{border:1px solid silver;margin:0 2px;padding:.35em .625em .75em}legend{box-sizing:border-box;color:inherit;display:table;max-width:100%;padding:0;white-space:normal}textarea{overflow:auto}[type=checkbox],[type=radio]{box-sizing:border-box;padding:0}[type=number]::-webkit-inner-spin-button,[type=number]::-webkit-outer-spin-button{height:auto}[type=search]{-webkit-appearance:textfield;outline-offset:-2px}[type=search]::-webkit-search-cancel-button,[type=search]::-webkit-search-decoration{-webkit-appearance:none}::-webkit-input-placeholder{color:inherit;opacity:.54}::-webkit-file-upload-button{-webkit-appearance:button;font:inherit}html{font-size:100%;box-sizing:border-box}*{box-sizing:inherit}*::before,*::after{box-sizing:inherit}body{color:#161616;font-family:var(--bpk-base-font-stack, "Skyscanner Relative", "Noto Sans Arabic", "Noto Sans Hebrew", "Noto Sans", "Noto Sans Devanagari", "Noto Sans Thai", "Noto Sans
|
|
19
|
+
*//*! normalize.css v4.1.1 | MIT License | github.com/necolas/normalize.css */html{font-family:sans-serif;line-height:1.15;-ms-text-size-adjust:100%;-webkit-text-size-adjust:100%}body{margin:0}article,aside,details,figcaption,figure,footer,header,main,menu,nav,section,summary{display:block}audio,canvas,progress,video{display:inline-block}audio:not([controls]){display:none;height:0}progress{vertical-align:baseline}template,[hidden]{display:none}a{background-color:rgba(0,0,0,0);-webkit-text-decoration-skip:objects}a:active,a:hover{outline-width:0}abbr[title]{border-bottom:none;text-decoration:underline;text-decoration:underline dotted}b,strong{font-weight:inherit}b,strong{font-weight:bolder}dfn{font-style:italic}h1{font-size:2em;margin:.67em 0}mark{background-color:#ff0;color:#000}small{font-size:80%}sub,sup{font-size:75%;line-height:0;position:relative;vertical-align:baseline}sub{bottom:-0.25em}sup{top:-0.5em}img{border-style:none}svg:not(:root){overflow:hidden}code,kbd,pre,samp{font-family:monospace,monospace;font-size:1em}figure{margin:1em 40px}hr{box-sizing:content-box;height:0;overflow:visible}button,input,optgroup,select,textarea{font:inherit;margin:0}optgroup{font-weight:bold}button,input{overflow:visible}button,select{text-transform:none}button,html [type=button],[type=reset],[type=submit]{-webkit-appearance:button}button::-moz-focus-inner,[type=button]::-moz-focus-inner,[type=reset]::-moz-focus-inner,[type=submit]::-moz-focus-inner{border-style:none;padding:0}button:-moz-focusring,[type=button]:-moz-focusring,[type=reset]:-moz-focusring,[type=submit]:-moz-focusring{outline:1px dotted ButtonText}fieldset{border:1px solid silver;margin:0 2px;padding:.35em .625em .75em}legend{box-sizing:border-box;color:inherit;display:table;max-width:100%;padding:0;white-space:normal}textarea{overflow:auto}[type=checkbox],[type=radio]{box-sizing:border-box;padding:0}[type=number]::-webkit-inner-spin-button,[type=number]::-webkit-outer-spin-button{height:auto}[type=search]{-webkit-appearance:textfield;outline-offset:-2px}[type=search]::-webkit-search-cancel-button,[type=search]::-webkit-search-decoration{-webkit-appearance:none}::-webkit-input-placeholder{color:inherit;opacity:.54}::-webkit-file-upload-button{-webkit-appearance:button;font:inherit}html{font-size:100%;box-sizing:border-box}*{box-sizing:inherit}*::before,*::after{box-sizing:inherit}body{color:#161616;font-family:var(--bpk-base-font-stack, "Skyscanner Relative", "Noto Sans Arabic", "Noto Sans Hebrew", "Noto Sans", "Noto Sans Devanagari", "Noto Sans Thai", "Noto Sans TC", "Noto Sans JP", "Noto Sans KR", "Noto Sans SC", -apple-system, BlinkMacSystemFont, "Roboto", "Oxygen", "Ubuntu", "Cantarell", "Fira Sans", "Droid Sans", "Helvetica Neue", sans-serif);font-size:1rem;line-height:1.3rem}body.scaffold-font-size{font-size:13px}body.enable-font-smoothing{-webkit-font-smoothing:antialiased}:focus-visible{outline:.125rem solid #0062e3;outline-offset:.125rem}.hidden,.hide{display:none !important}.visuallyhidden,.visually-hidden{position:absolute;width:1px;height:1px;margin:-1px;padding:0;border:0;white-space:nowrap;overflow:hidden;clip:rect(0 0 0 0)}.visuallyhidden.focusable:active,.visuallyhidden.focusable:focus,.visually-hidden.focusable:active,.visually-hidden.focusable:focus{position:static;width:auto;height:auto;margin:0;overflow:visible;clip:auto}.invisible{visibility:hidden}.clearfix::before,.clearfix::after{content:"";display:table}.clearfix::after{clear:both}
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@skyscanner/backpack-web",
|
|
3
|
-
"version": "42.
|
|
3
|
+
"version": "42.7.0",
|
|
4
4
|
"description": "Backpack Design System web library",
|
|
5
5
|
"repository": {
|
|
6
6
|
"type": "git",
|
|
@@ -29,7 +29,7 @@
|
|
|
29
29
|
"@radix-ui/react-compose-refs": "^1.1.1",
|
|
30
30
|
"@radix-ui/react-slider": "1.3.5",
|
|
31
31
|
"@react-google-maps/api": "^2.19.3",
|
|
32
|
-
"@skyscanner/bpk-foundations-web": "^24.
|
|
32
|
+
"@skyscanner/bpk-foundations-web": "^24.4.0",
|
|
33
33
|
"@skyscanner/bpk-svgs": "^20.11.0",
|
|
34
34
|
"a11y-focus-scope": "^1.1.3",
|
|
35
35
|
"a11y-focus-store": "^1.0.0",
|