@telefonica/mistica 10.0.1 → 10.3.1

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (69) hide show
  1. package/CHANGELOG.md +43 -0
  2. package/dist/button-fixed-footer-layout.d.ts +2 -2
  3. package/dist/button-layout.d.ts +2 -2
  4. package/dist/button.d.ts +1 -1
  5. package/dist/callout.d.ts +4 -3
  6. package/dist/card.d.ts +9 -7
  7. package/dist/circle.d.ts +1 -1
  8. package/dist/dialog.d.ts +1 -1
  9. package/dist/double-field.d.ts +11 -1
  10. package/dist/double-field.js.flow +20 -20
  11. package/dist/empty-state-card.d.ts +1 -1
  12. package/dist/empty-state-card.js.flow +0 -1
  13. package/dist/empty-state.d.ts +1 -1
  14. package/dist/empty-state.js.flow +0 -1
  15. package/dist/feedback-screen.d.ts +4 -3
  16. package/dist/header.d.ts +7 -5
  17. package/dist/highlighted-card.d.ts +2 -2
  18. package/dist/icon-button.js +4 -6
  19. package/dist/list.js +9 -14
  20. package/dist/navigation-bar.d.ts +16 -4
  21. package/dist/navigation-bar.js +123 -88
  22. package/dist/navigation-bar.js.flow +20 -4
  23. package/dist/navigation-breadcrumbs.d.ts +1 -1
  24. package/dist/navigation-breadcrumbs.js.flow +1 -1
  25. package/dist/password-field.js +16 -8
  26. package/dist/radio-button.d.ts +1 -1
  27. package/dist/section-title.d.ts +2 -1
  28. package/dist/select.js +74 -65
  29. package/dist/skins/movistar.js +1 -1
  30. package/dist/skins/o2-classic.js +1 -1
  31. package/dist/skins/o2.js +1 -1
  32. package/dist/skins/telefonica.js +1 -1
  33. package/dist/skins/vivo.js +1 -1
  34. package/dist/switch-component.d.ts +1 -1
  35. package/dist/tabs.js +10 -8
  36. package/dist/tag.d.ts +2 -2
  37. package/dist/tag.js.flow +2 -2
  38. package/dist/text-field-base.js +80 -50
  39. package/dist/text-field-components.d.ts +1 -0
  40. package/dist/text-field-components.js +18 -9
  41. package/dist/text-field-components.js.flow +1 -0
  42. package/dist/text-link.d.ts +2 -2
  43. package/dist/text-link.js +20 -23
  44. package/dist/text-link.js.flow +2 -2
  45. package/dist/theme-context-provider.js +2 -2
  46. package/dist/theme.d.ts +2 -0
  47. package/dist/theme.js +8 -4
  48. package/dist/theme.js.flow +2 -0
  49. package/dist/utils/media-queries.d.ts +1 -0
  50. package/dist/utils/media-queries.js +6 -1
  51. package/dist/utils/media-queries.js.flow +1 -0
  52. package/dist-es/icon-button.js +4 -5
  53. package/dist-es/list.js +9 -14
  54. package/dist-es/navigation-bar.js +122 -88
  55. package/dist-es/password-field.js +16 -8
  56. package/dist-es/select.js +74 -65
  57. package/dist-es/skins/movistar.js +1 -1
  58. package/dist-es/skins/o2-classic.js +1 -1
  59. package/dist-es/skins/o2.js +1 -1
  60. package/dist-es/skins/telefonica.js +1 -1
  61. package/dist-es/skins/vivo.js +1 -1
  62. package/dist-es/tabs.js +10 -8
  63. package/dist-es/text-field-base.js +80 -50
  64. package/dist-es/text-field-components.js +18 -9
  65. package/dist-es/text-link.js +7 -10
  66. package/dist-es/theme-context-provider.js +2 -2
  67. package/dist-es/theme.js +8 -4
  68. package/dist-es/utils/media-queries.js +6 -1
  69. package/package.json +2 -1
@@ -336,21 +336,30 @@ var useFieldContainerStyles = (0, _jss.createUseStyles)(function (theme) {
336
336
  display: 'flex',
337
337
  position: 'relative',
338
338
  lineHeight: '16px',
339
- backgroundColor: theme.colors.backgroundContainer
339
+ backgroundColor: function backgroundColor(_ref10) {
340
+ var disabled = _ref10.disabled;
341
+ return disabled ? theme.colors.backgroundAlternative : theme.colors.backgroundContainer;
342
+ },
343
+ cursor: function cursor(_ref11) {
344
+ var disabled = _ref11.disabled;
345
+ return disabled ? 'not-allowed' : 'initial';
346
+ }
340
347
  }
341
348
  };
342
349
  });
343
350
 
344
- var FieldContainer = function FieldContainer(_ref10) {
345
- var multiline = _ref10.multiline,
346
- children = _ref10.children,
347
- helperText = _ref10.helperText,
348
- className = _ref10.className,
349
- fieldRef = _ref10.fieldRef,
350
- fullWidth = _ref10.fullWidth;
351
+ var FieldContainer = function FieldContainer(_ref12) {
352
+ var multiline = _ref12.multiline,
353
+ disabled = _ref12.disabled,
354
+ children = _ref12.children,
355
+ helperText = _ref12.helperText,
356
+ className = _ref12.className,
357
+ fieldRef = _ref12.fieldRef,
358
+ fullWidth = _ref12.fullWidth;
351
359
  var classes = useFieldContainerStyles({
352
360
  multiline: multiline,
353
- fullWidth: fullWidth
361
+ fullWidth: fullWidth,
362
+ disabled: disabled
354
363
  });
355
364
  return /*#__PURE__*/React.createElement("div", {
356
365
  className: classes.fieldContainer
@@ -22,6 +22,7 @@ declare type HelperTextProps = {
22
22
  declare export var HelperText: React.ComponentType<HelperTextProps>;
23
23
  declare type FieldContainerProps = {
24
24
  multiline?: boolean,
25
+ disabled?: boolean,
25
26
  children: React.Node,
26
27
  helperText?: React.Node,
27
28
  className?: string,
@@ -29,6 +29,6 @@ export interface OnPressProps extends CommonProps {
29
29
  href?: undefined;
30
30
  to?: undefined;
31
31
  }
32
- declare type Props = HrefProps | ToProps | OnPressProps;
33
- declare const TextLink: React.FC<Props>;
32
+ export declare type TextLinkProps = HrefProps | ToProps | OnPressProps;
33
+ declare const TextLink: React.FC<TextLinkProps>;
34
34
  export default TextLink;
package/dist/text-link.js CHANGED
@@ -43,21 +43,6 @@ function _extends() {
43
43
  return _extends.apply(this, arguments);
44
44
  }
45
45
 
46
- function _defineProperty(obj, key, value) {
47
- if (key in obj) {
48
- Object.defineProperty(obj, key, {
49
- value: value,
50
- enumerable: true,
51
- configurable: true,
52
- writable: true
53
- });
54
- } else {
55
- obj[key] = value;
56
- }
57
-
58
- return obj;
59
- }
60
-
61
46
  function _objectWithoutProperties(source, excluded) {
62
47
  if (source == null) return {};
63
48
 
@@ -94,22 +79,34 @@ function _objectWithoutPropertiesLoose(source, excluded) {
94
79
  return target;
95
80
  }
96
81
 
82
+ function _defineProperty(obj, key, value) {
83
+ if (key in obj) {
84
+ Object.defineProperty(obj, key, {
85
+ value: value,
86
+ enumerable: true,
87
+ configurable: true,
88
+ writable: true
89
+ });
90
+ } else {
91
+ obj[key] = value;
92
+ }
93
+
94
+ return obj;
95
+ }
96
+
97
97
  var useStyles = (0, _jss.createUseStyles)(function (theme) {
98
98
  return {
99
- textLink: {
99
+ textLink: _defineProperty({
100
100
  width: 'auto',
101
101
  lineHeight: 'inherit',
102
102
  display: 'inline-block',
103
103
  color: theme.colors.textLink,
104
- wordBreak: 'break-word',
104
+ wordBreak: 'break-word'
105
+ }, theme.mq.supportsHover, {
105
106
  '&:hover': {
106
- textDecoration: 'underline',
107
- // Revert hover effect in touch devices
108
- '@media (pointer: coarse)': {
109
- textDecoration: 'initial'
110
- }
107
+ textDecoration: 'underline'
111
108
  }
112
- },
109
+ }),
113
110
  inverse: {
114
111
  color: theme.colors.textLinkInverse
115
112
  },
@@ -29,8 +29,8 @@ export type OnPressProps = {|
29
29
  ...$Exact<CommonProps>,
30
30
  onPress: (event: SyntheticMouseEvent<HTMLElement>) => void | boolean,
31
31
  |};
32
- declare type Props = HrefProps | ToProps | OnPressProps;
33
- declare var TextLink: React.ComponentType<Props>;
32
+ export type TextLinkProps = HrefProps | ToProps | OnPressProps;
33
+ declare var TextLink: React.ComponentType<TextLinkProps>;
34
34
  declare export default typeof TextLink;
35
35
 
36
36
  import { type CssStyle } from "./__types__.js.flow";
@@ -227,7 +227,7 @@ var ThemeContextProvider = function ThemeContextProvider(_ref) {
227
227
  }, []);
228
228
  var isOsDarkModeEnabled = useIsOsDarkModeEnabled();
229
229
  var contextTheme = React.useMemo(function () {
230
- var _theme$colorScheme, _theme$Link; // TODO: In next major version we could change this to "auto" by default
230
+ var _theme$colorScheme, _theme$mediaQueries, _theme$Link; // TODO: In next major version we could change this to "auto" by default
231
231
 
232
232
 
233
233
  var colorScheme = (_theme$colorScheme = theme.colorScheme) !== null && _theme$colorScheme !== void 0 ? _theme$colorScheme : 'light';
@@ -254,7 +254,7 @@ var ThemeContextProvider = function ThemeContextProvider(_ref) {
254
254
  }
255
255
  }, theme.analytics),
256
256
  dimensions: _objectSpread(_objectSpread({}, _theme.dimensions), theme.dimensions),
257
- mq: theme.mediaQueries ? (0, _mediaQueries.createMediaQueries)(theme.mediaQueries) : (0, _mediaQueries.createMediaQueries)(_theme.mediaQueriesConfig),
257
+ mq: (0, _mediaQueries.createMediaQueries)((_theme$mediaQueries = theme.mediaQueries) !== null && _theme$mediaQueries !== void 0 ? _theme$mediaQueries : _theme.mediaQueriesConfig),
258
258
  colors: colors,
259
259
  Link: (_theme$Link = theme.Link) !== null && _theme$Link !== void 0 ? _theme$Link : _theme.AnchorLink,
260
260
  isDarkMode: isDarkModeEnabled,
package/dist/theme.d.ts CHANGED
@@ -31,6 +31,7 @@ declare const TEXTS_ES: {
31
31
  menuLabelSuffix: string;
32
32
  openNavigationMenu: string;
33
33
  closeNavigationMenu: string;
34
+ backNavigationBar: string;
34
35
  };
35
36
  export declare const getTexts: (locale: Locale) => typeof TEXTS_ES;
36
37
  export declare const dimensions: {
@@ -124,6 +125,7 @@ export declare type Theme = {
124
125
  tabletOrBigger: string;
125
126
  tabletOrSmaller: string;
126
127
  desktopOrBigger: string;
128
+ supportsHover: string;
127
129
  };
128
130
  colors: Colors;
129
131
  Link: LinkComponent;
package/dist/theme.js CHANGED
@@ -95,7 +95,8 @@ var TEXTS_ES = {
95
95
  formSearchClear: 'Borrar búsqueda',
96
96
  menuLabelSuffix: 'menú',
97
97
  openNavigationMenu: 'Abrir menú de navegación',
98
- closeNavigationMenu: 'Cerrar menú de navegación'
98
+ closeNavigationMenu: 'Cerrar menú de navegación',
99
+ backNavigationBar: 'Atrás'
99
100
  };
100
101
  var TEXTS_EN = {
101
102
  expirationDatePlaceholder: 'MM/YY',
@@ -123,7 +124,8 @@ var TEXTS_EN = {
123
124
  formSearchClear: 'Clear search',
124
125
  menuLabelSuffix: 'menu',
125
126
  openNavigationMenu: 'Open navigation menu',
126
- closeNavigationMenu: 'Close navigation menu'
127
+ closeNavigationMenu: 'Close navigation menu',
128
+ backNavigationBar: 'Back'
127
129
  };
128
130
  var TEXTS_DE = {
129
131
  expirationDatePlaceholder: 'MM/JJ',
@@ -151,7 +153,8 @@ var TEXTS_DE = {
151
153
  formSearchClear: 'Suche löschen',
152
154
  menuLabelSuffix: 'Menü',
153
155
  openNavigationMenu: 'Navigationsmenü öffnen',
154
- closeNavigationMenu: 'Navigationsmenü schließen'
156
+ closeNavigationMenu: 'Navigationsmenü schließen',
157
+ backNavigationBar: 'Zurück'
155
158
  };
156
159
  var TEXTS_PT = {
157
160
  expirationDatePlaceholder: 'MM/AA',
@@ -179,7 +182,8 @@ var TEXTS_PT = {
179
182
  formSearchClear: 'Apagar pesquisa',
180
183
  menuLabelSuffix: 'menu',
181
184
  openNavigationMenu: 'Abrir menu de navegação',
182
- closeNavigationMenu: 'Fechar menu de navegação'
185
+ closeNavigationMenu: 'Fechar menu de navegação',
186
+ backNavigationBar: 'Voltar'
183
187
  };
184
188
 
185
189
  var getTexts = function getTexts(locale) {
@@ -33,6 +33,7 @@ declare var TEXTS_ES: {
33
33
  menuLabelSuffix: string,
34
34
  openNavigationMenu: string,
35
35
  closeNavigationMenu: string,
36
+ backNavigationBar: string,
36
37
  };
37
38
  declare export var getTexts: (locale: Locale) => typeof TEXTS_ES;
38
39
  declare export var dimensions: {
@@ -128,6 +129,7 @@ export type Theme = {
128
129
  tabletOrBigger: string,
129
130
  tabletOrSmaller: string,
130
131
  desktopOrBigger: string,
132
+ supportsHover: string,
131
133
  },
132
134
  colors: Colors,
133
135
  Link: LinkComponent,
@@ -11,4 +11,5 @@ export declare const createMediaQueries: ({ desktopOrTabletMinHeight, tabletMinW
11
11
  tabletOrBigger: string;
12
12
  tabletOrSmaller: string;
13
13
  desktopOrBigger: string;
14
+ supportsHover: string;
14
15
  };
@@ -17,7 +17,12 @@ var createMediaQueries = function createMediaQueries(_ref) {
17
17
  largeDesktop: "@media only screen " + "and (min-height: ".concat(desktopOrTabletMinHeight, "px) ") + "and (min-width: ".concat(largeDesktopMinWidth, "px)"),
18
18
  tabletOrBigger: "@media only screen " + "and (min-height: ".concat(desktopOrTabletMinHeight, "px) ") + "and (min-width: ".concat(tabletMinWidth, "px)"),
19
19
  tabletOrSmaller: "@media only screen and (max-width: ".concat(desktopMinWidth - 1, "px), ") + "(max-height: ".concat(desktopOrTabletMinHeight - 1, "px)"),
20
- desktopOrBigger: "@media only screen " + "and (min-height: ".concat(desktopOrTabletMinHeight, "px) ") + "and (min-width: ".concat(desktopMinWidth, "px)")
20
+ desktopOrBigger: "@media only screen " + "and (min-height: ".concat(desktopOrTabletMinHeight, "px) ") + "and (min-width: ".concat(desktopMinWidth, "px)"),
21
+ // Only apply hover effect to user agents using fine pointer devices (a mouse, for example)
22
+ // Also enabled for (pointer: none) for acceptance tests, where (pointer: fine) doesn't match.
23
+ // WARNING: you may be tempted to use @media (hover: hover) instead, but that doesn't work as expected in some android browsers.
24
+ // See: https://hover-pointer-media-query.glitch.me/ and https://github.com/mui-org/material-ui/issues/15736
25
+ supportsHover: '@media (pointer: fine), (pointer: none)'
21
26
  };
22
27
  };
23
28
 
@@ -13,4 +13,5 @@ declare export var createMediaQueries: (x: {
13
13
  tabletOrBigger: string,
14
14
  tabletOrSmaller: string,
15
15
  desktopOrBigger: string,
16
+ supportsHover: string,
16
17
  };
@@ -8,7 +8,6 @@ function _defineProperty(obj, key, value) { if (key in obj) { Object.definePrope
8
8
 
9
9
  import * as React from 'react';
10
10
  import Touchable from './touchable';
11
- import { getPrefixedDataAttributes } from './utils/dom';
12
11
  var ICON_SIZE_1 = 24;
13
12
 
14
13
  var getButtonStyle = function getButtonStyle(backgroundUrl, size, backgroundColor, iconSize, disabled) {
@@ -51,14 +50,14 @@ var IconButton = function IconButton(props) {
51
50
  iconSize = props.iconSize,
52
51
  _props$size = props.size,
53
52
  size = _props$size === void 0 ? ICON_SIZE_1 : _props$size;
54
-
55
- var commonProps = _objectSpread({
53
+ var commonProps = {
56
54
  className: props.className || '',
57
55
  disabled: props.disabled,
58
56
  style: _objectSpread(_objectSpread({}, getButtonStyle(icon, size, backgroundColor, iconSize, props.disabled)), props.style),
59
57
  trackingEvent: props.trackingEvent,
60
- 'aria-live': props['aria-live']
61
- }, getPrefixedDataAttributes(props.dataAttributes));
58
+ 'aria-live': props['aria-live'],
59
+ dataAttributes: props.dataAttributes
60
+ };
62
61
 
63
62
  if (props.href) {
64
63
  return /*#__PURE__*/React.createElement(Touchable, _extends({}, commonProps, {
package/dist-es/list.js CHANGED
@@ -38,22 +38,17 @@ import { Boxed } from './boxed';
38
38
  import Divider from './divider';
39
39
  import { getPrefixedDataAttributes } from './utils/dom';
40
40
  var useStyles = createUseStyles(function (_ref) {
41
- var colors = _ref.colors;
41
+ var colors = _ref.colors,
42
+ mq = _ref.mq;
42
43
  return {
43
- hover: {
44
- // Only apply hover effect to user agents using fine pointer devices (a mouse, for example)
45
- // Also enabled for (pointer: none) for acceptance tests, where (pointer: fine) doesn't match.
46
- // WARNING: you may be tempted to use @media (hover: hover) instead, but that doesn't work as expected in some android browsers.
47
- // See: https://hover-pointer-media-query.glitch.me/ and https://github.com/mui-org/material-ui/issues/15736
48
- '@media (pointer: fine), (pointer: none)': {
49
- '&:hover': {
50
- background: function background(_ref2) {
51
- var isInverse = _ref2.isInverse;
52
- return isInverse ? 'initial' : colors.backgroundAlternative;
53
- }
44
+ hover: _defineProperty({}, mq.supportsHover, {
45
+ '&:hover': {
46
+ background: function background(_ref2) {
47
+ var isInverse = _ref2.isInverse;
48
+ return isInverse ? 'initial' : colors.backgroundAlternative;
54
49
  }
55
50
  }
56
- },
51
+ }),
57
52
  rowContent: {
58
53
  width: '100%',
59
54
  cursor: 'pointer'
@@ -415,7 +410,7 @@ var RowContent = function RowContent(props) {
415
410
 
416
411
  return /*#__PURE__*/React.createElement(Box, {
417
412
  paddingX: 16,
418
- className: classNames(classNames(classes.rowContent, classes.hover), classes.hoverDisabled),
413
+ className: classNames(classes.rowContent, classes.hover, classes.hoverDisabled),
419
414
  role: role
420
415
  }, props.right ? renderContent({
421
416
  type: 'custom',
@@ -26,6 +26,7 @@ import { CSSTransition } from 'react-transition-group';
26
26
  import classnames from 'classnames';
27
27
  import ResponsiveLayout from './responsive-layout';
28
28
  import Inline from './inline';
29
+ import Box from './box';
29
30
  import Touchable from './touchable';
30
31
  import { Text2, Text3 } from './text';
31
32
  import { useScreenSize, useTheme, useAriaId } from './hooks';
@@ -252,54 +253,60 @@ var useStyles = createUseStyles(function (theme) {
252
253
  right: 0,
253
254
  zIndex: NAVBAR_ZINDEX
254
255
  },
256
+ notFixedPadding: {
257
+ width: '100%',
258
+ padding: function padding(_ref7) {
259
+ var paddingX = _ref7.paddingX;
260
+ return "0 ".concat(paddingX, "px");
261
+ }
262
+ },
255
263
  navbar: _defineProperty({
256
264
  width: '100%',
257
265
  display: 'flex',
258
266
  alignItems: 'center',
259
- background: function background(_ref7) {
260
- var isInverse = _ref7.isInverse;
267
+ background: function background(_ref8) {
268
+ var isInverse = _ref8.isInverse;
261
269
  return isInverse ? theme.colors.navigationBarBackground : theme.colors.background;
262
270
  },
263
271
  height: DESKTOP_NAVBAR_HEIGHT,
264
272
  padding: '16px 0',
265
- transition: 'border 300ms',
266
- borderBottom: "1px solid ".concat(theme.colors.divider),
267
- borderColor: function borderColor(_ref8) {
268
- var isInverse = _ref8.isInverse;
273
+ borderBottomStyle: 'solid',
274
+ borderBottomWidth: function borderBottomWidth(_ref9) {
275
+ var withBorder = _ref9.withBorder;
276
+ return withBorder ? 1 : 0;
277
+ },
278
+ borderColor: function borderColor(_ref10) {
279
+ var isInverse = _ref10.isInverse;
269
280
  return isInverse && !theme.isDarkMode ? 'transparent' : theme.colors.divider;
270
281
  }
271
282
  }, theme.mq.tabletOrSmaller, {
272
- borderColor: function borderColor(_ref9) {
273
- var isMenuOpen = _ref9.isMenuOpen,
274
- isInverse = _ref9.isInverse;
283
+ transition: 'border-color 300ms',
284
+ borderColor: function borderColor(_ref11) {
285
+ var isMenuOpen = _ref11.isMenuOpen,
286
+ isInverse = _ref11.isInverse;
275
287
  return isMenuOpen || isInverse && !theme.isDarkMode ? 'transparent' : theme.colors.divider;
276
288
  },
277
289
  height: MOBILE_NAVBAR_HEIGHT,
278
290
  padding: '8px 0'
279
291
  }),
280
- section: {
292
+ section: _defineProperty({
281
293
  height: DESKTOP_NAVBAR_HEIGHT,
282
294
  display: 'flex',
283
295
  alignItems: 'center',
284
296
  padding: '0 8px',
285
297
  borderBottom: "2px solid transparent",
286
- transition: 'border-color 300ms ease-in-out',
287
- // Only apply hover effect to user agents using fine pointer devices (a mouse, for example)
288
- // Also enabled for (pointer: none) for acceptance tests, where (pointer: fine) doesn't match.
289
- // WARNING: you may be tempted to use @media (hover: hover) instead, but that doesn't work as expected in some android browsers.
290
- // See: https://hover-pointer-media-query.glitch.me/ and https://github.com/mui-org/material-ui/issues/15736
291
- '@media (pointer: fine), (pointer: none)': {
292
- '&:hover span': {
293
- color: function color(_ref10) {
294
- var isInverse = _ref10.isInverse;
295
- return isInverse ? theme.colors.textSecondaryInverse : theme.colors.textSecondary;
296
- }
298
+ transition: 'border-color 300ms ease-in-out'
299
+ }, theme.mq.supportsHover, {
300
+ '&:hover span': {
301
+ color: function color(_ref12) {
302
+ var isInverse = _ref12.isInverse;
303
+ return isInverse ? theme.colors.textSecondaryInverse : theme.colors.textSecondary;
297
304
  }
298
305
  }
299
- },
306
+ }),
300
307
  selectedSection: {
301
- borderColor: function borderColor(_ref11) {
302
- var isInverse = _ref11.isInverse;
308
+ borderColor: function borderColor(_ref13) {
309
+ var isInverse = _ref13.isInverse;
303
310
  return isInverse ? theme.colors.inverse : theme.colors.controlActivated;
304
311
  }
305
312
  },
@@ -317,8 +324,8 @@ var useStyles = createUseStyles(function (theme) {
317
324
  height: "calc(100vh - ".concat(MOBILE_NAVBAR_HEIGHT, "px)"),
318
325
  overflowY: 'auto',
319
326
  background: theme.colors.background,
320
- boxShadow: function boxShadow(_ref12) {
321
- var menuTransitionState = _ref12.menuTransitionState;
327
+ boxShadow: function boxShadow(_ref14) {
328
+ var menuTransitionState = _ref14.menuTransitionState;
322
329
  return menuTransitionState !== 'closed' ? "6px 0 4px -4px rgba(0, 0, 0, ".concat(shadowAlpha, ")") : 'none';
323
330
  },
324
331
  transition: "transform ".concat(BURGER_MENU_ANIMATION_DURATION_MS, "ms ease-out")
@@ -334,20 +341,33 @@ var useStyles = createUseStyles(function (theme) {
334
341
  },
335
342
  burgerMenuExitActive: {
336
343
  transform: 'translate(-100vw)'
337
- }
344
+ },
345
+ iconButton: _defineProperty({
346
+ color: function color(_ref15) {
347
+ var isInverse = _ref15.isInverse;
348
+ return isInverse ? theme.colors.inverse : theme.colors.neutralHigh;
349
+ }
350
+ }, theme.mq.supportsHover, {
351
+ '&:hover': {
352
+ color: function color(_ref16) {
353
+ var isInverse = _ref16.isInverse;
354
+ return isInverse ? theme.colors.inverse : theme.colors.neutralMedium;
355
+ }
356
+ }
357
+ })
338
358
  };
339
359
  });
340
- export var MainNavigationBar = function MainNavigationBar(_ref13) {
360
+ export var MainNavigationBar = function MainNavigationBar(_ref17) {
341
361
  var _logo;
342
362
 
343
- var sections = _ref13.sections,
344
- selectedIndex = _ref13.selectedIndex,
345
- right = _ref13.right,
346
- logo = _ref13.logo,
347
- _ref13$isInverse = _ref13.isInverse,
348
- isInverse = _ref13$isInverse === void 0 ? false : _ref13$isInverse,
349
- _ref13$topFixed = _ref13.topFixed,
350
- topFixed = _ref13$topFixed === void 0 ? true : _ref13$topFixed;
363
+ var sections = _ref17.sections,
364
+ selectedIndex = _ref17.selectedIndex,
365
+ right = _ref17.right,
366
+ logo = _ref17.logo,
367
+ _ref17$isInverse = _ref17.isInverse,
368
+ isInverse = _ref17$isInverse === void 0 ? false : _ref17$isInverse,
369
+ _ref17$topFixed = _ref17.topFixed,
370
+ topFixed = _ref17$topFixed === void 0 ? true : _ref17$topFixed;
351
371
 
352
372
  var _useTheme6 = useTheme(),
353
373
  texts = _useTheme6.texts;
@@ -366,7 +386,8 @@ export var MainNavigationBar = function MainNavigationBar(_ref13) {
366
386
  var classes = useStyles({
367
387
  isMenuOpen: isMenuOpen,
368
388
  isInverse: isInverse,
369
- menuTransitionState: menuTransitionState
389
+ menuTransitionState: menuTransitionState,
390
+ withBorder: true
370
391
  });
371
392
 
372
393
  var _useScreenSize2 = useScreenSize(),
@@ -465,9 +486,9 @@ export var MainNavigationBar = function MainNavigationBar(_ref13) {
465
486
  alignItems: "center"
466
487
  }, logo, /*#__PURE__*/React.createElement("nav", null, /*#__PURE__*/React.createElement(Inline, {
467
488
  space: 32
468
- }, sections.map(function (_ref14, idx) {
469
- var title = _ref14.title,
470
- touchableProps = _objectWithoutProperties(_ref14, _excluded);
489
+ }, sections.map(function (_ref18, idx) {
490
+ var title = _ref18.title,
491
+ touchableProps = _objectWithoutProperties(_ref18, _excluded);
471
492
 
472
493
  return /*#__PURE__*/React.createElement(Touchable, _extends({}, touchableProps, {
473
494
  key: idx,
@@ -479,16 +500,25 @@ export var MainNavigationBar = function MainNavigationBar(_ref13) {
479
500
  className: classes.spacer
480
501
  }));
481
502
  };
482
- export var NavigationBar = function NavigationBar(_ref15) {
483
- var onBack = _ref15.onBack,
484
- title = _ref15.title,
485
- right = _ref15.right,
486
- _ref15$isInverse = _ref15.isInverse,
487
- isInverse = _ref15$isInverse === void 0 ? false : _ref15$isInverse,
488
- _ref15$topFixed = _ref15.topFixed,
489
- topFixed = _ref15$topFixed === void 0 ? true : _ref15$topFixed;
503
+ export var NavigationBar = function NavigationBar(_ref19) {
504
+ var onBack = _ref19.onBack,
505
+ title = _ref19.title,
506
+ right = _ref19.right,
507
+ _ref19$isInverse = _ref19.isInverse,
508
+ isInverse = _ref19$isInverse === void 0 ? false : _ref19$isInverse,
509
+ _ref19$topFixed = _ref19.topFixed,
510
+ topFixed = _ref19$topFixed === void 0 ? true : _ref19$topFixed,
511
+ paddingX = _ref19.paddingX,
512
+ _ref19$withBorder = _ref19.withBorder,
513
+ withBorder = _ref19$withBorder === void 0 ? true : _ref19$withBorder;
514
+
515
+ var _useTheme7 = useTheme(),
516
+ texts = _useTheme7.texts;
517
+
490
518
  var classes = useStyles({
491
- isInverse: isInverse
519
+ isInverse: isInverse,
520
+ paddingX: paddingX !== null && paddingX !== void 0 ? paddingX : 0,
521
+ withBorder: withBorder
492
522
  });
493
523
  var content = /*#__PURE__*/React.createElement(Inline, {
494
524
  space: "between",
@@ -497,28 +527,37 @@ export var NavigationBar = function NavigationBar(_ref15) {
497
527
  space: 24,
498
528
  alignItems: "center"
499
529
  }, onBack && /*#__PURE__*/React.createElement(IconButton, {
500
- "aria-label": "back",
501
- onPress: onBack
502
- }, /*#__PURE__*/React.createElement(IconChevronLeftRegular, null)), /*#__PURE__*/React.createElement(Text3, {
503
- regular: true
504
- }, title)), right);
530
+ "aria-label": texts.backNavigationBar,
531
+ onPress: onBack,
532
+ className: classes.iconButton
533
+ }, /*#__PURE__*/React.createElement(IconChevronLeftRegular, {
534
+ color: "currentColor"
535
+ })), /*#__PURE__*/React.createElement(Text3, {
536
+ regular: true,
537
+ truncate: true
538
+ }, title)), /*#__PURE__*/React.createElement(Box, {
539
+ paddingLeft: 24
540
+ }, right));
505
541
  return /*#__PURE__*/React.createElement(ThemeVariant, {
506
542
  isInverse: isInverse
507
543
  }, /*#__PURE__*/React.createElement("header", {
508
544
  className: classnames(classes.navbar, _defineProperty({}, classes.topFixed, topFixed))
509
- }, topFixed ? /*#__PURE__*/React.createElement(ResponsiveLayout, null, content) : content), topFixed && /*#__PURE__*/React.createElement("div", {
545
+ }, topFixed ? /*#__PURE__*/React.createElement(ResponsiveLayout, null, content) : /*#__PURE__*/React.createElement("div", {
546
+ className: classes.notFixedPadding
547
+ }, content)), topFixed && /*#__PURE__*/React.createElement("div", {
510
548
  className: classes.spacer
511
549
  }));
512
550
  };
513
- export var FunnelNavigationBar = function FunnelNavigationBar(_ref16) {
514
- var logo = _ref16.logo,
515
- right = _ref16.right,
516
- _ref16$isInverse = _ref16.isInverse,
517
- isInverse = _ref16$isInverse === void 0 ? false : _ref16$isInverse,
518
- _ref16$topFixed = _ref16.topFixed,
519
- topFixed = _ref16$topFixed === void 0 ? true : _ref16$topFixed;
551
+ export var FunnelNavigationBar = function FunnelNavigationBar(_ref20) {
552
+ var logo = _ref20.logo,
553
+ right = _ref20.right,
554
+ _ref20$isInverse = _ref20.isInverse,
555
+ isInverse = _ref20$isInverse === void 0 ? false : _ref20$isInverse,
556
+ _ref20$topFixed = _ref20.topFixed,
557
+ topFixed = _ref20$topFixed === void 0 ? true : _ref20$topFixed;
520
558
  var classes = useStyles({
521
- isInverse: isInverse
559
+ isInverse: isInverse,
560
+ withBorder: true
522
561
  });
523
562
  return /*#__PURE__*/React.createElement(ThemeVariant, {
524
563
  isInverse: isInverse
@@ -542,8 +581,8 @@ var useNavigationBarActionGroupStyles = createUseStyles(function () {
542
581
  }
543
582
  };
544
583
  });
545
- export var NavigationBarActionGroup = function NavigationBarActionGroup(_ref17) {
546
- var children = _ref17.children;
584
+ export var NavigationBarActionGroup = function NavigationBarActionGroup(_ref21) {
585
+ var children = _ref21.children;
547
586
  var classes = useNavigationBarActionGroupStyles();
548
587
  return /*#__PURE__*/React.createElement("div", {
549
588
  className: classes.lineHeightFix
@@ -554,38 +593,33 @@ export var NavigationBarActionGroup = function NavigationBarActionGroup(_ref17)
554
593
  };
555
594
  var useNavigationBarActionStyles = createUseStyles(function (theme) {
556
595
  return {
557
- touchable: {
596
+ touchable: _defineProperty({
558
597
  lineHeight: 0,
559
598
  '& svg': {
560
- color: function color(_ref18) {
561
- var isInverse = _ref18.isInverse;
599
+ color: function color(_ref22) {
600
+ var isInverse = _ref22.isInverse;
562
601
  return isInverse ? theme.colors.inverse : theme.colors.neutralHigh;
563
602
  }
603
+ }
604
+ }, theme.mq.supportsHover, {
605
+ '&:hover span': {
606
+ color: function color(_ref23) {
607
+ var isInverse = _ref23.isInverse;
608
+ return isInverse ? theme.colors.textSecondaryInverse : theme.colors.textSecondary;
609
+ }
564
610
  },
565
- // Only apply hover effect to user agents using fine pointer devices (a mouse, for example)
566
- // Also enabled for (pointer: none) for acceptance tests, where (pointer: fine) doesn't match.
567
- // WARNING: you may be tempted to use @media (hover: hover) instead, but that doesn't work as expected in some android browsers.
568
- // See: https://hover-pointer-media-query.glitch.me/ and https://github.com/mui-org/material-ui/issues/15736
569
- '@media (pointer: fine), (pointer: none)': {
570
- '&:hover span': {
571
- color: function color(_ref19) {
572
- var isInverse = _ref19.isInverse;
573
- return isInverse ? theme.colors.textSecondaryInverse : theme.colors.textSecondary;
574
- }
575
- },
576
- '&:hover svg': {
577
- color: function color(_ref20) {
578
- var isInverse = _ref20.isInverse;
579
- return isInverse ? theme.colors.inverse : theme.colors.neutralMedium;
580
- }
611
+ '&:hover svg': {
612
+ color: function color(_ref24) {
613
+ var isInverse = _ref24.isInverse;
614
+ return isInverse ? theme.colors.inverse : theme.colors.neutralMedium;
581
615
  }
582
616
  }
583
- }
617
+ })
584
618
  };
585
619
  });
586
- export var NavigationBarAction = function NavigationBarAction(_ref21) {
587
- var children = _ref21.children,
588
- touchableProps = _objectWithoutProperties(_ref21, _excluded2);
620
+ export var NavigationBarAction = function NavigationBarAction(_ref25) {
621
+ var children = _ref25.children,
622
+ touchableProps = _objectWithoutProperties(_ref25, _excluded2);
589
623
 
590
624
  var isInverse = useIsInverseVariant();
591
625
  var classes = useNavigationBarActionStyles({