framework7-react 7.0.8 → 8.0.0-beta.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 (148) hide show
  1. package/components/accordion-content.js +2 -2
  2. package/components/accordion-item.js +2 -11
  3. package/components/accordion-toggle.js +2 -2
  4. package/components/accordion.js +2 -2
  5. package/components/actions-button.d.ts +1 -1
  6. package/components/actions-button.js +4 -8
  7. package/components/actions-group.js +2 -2
  8. package/components/actions-label.js +4 -6
  9. package/components/actions.js +4 -14
  10. package/components/app.js +4 -8
  11. package/components/area-chart.js +6 -45
  12. package/components/badge.js +2 -2
  13. package/components/block-footer.js +2 -2
  14. package/components/block-header.js +2 -2
  15. package/components/block-title.js +2 -2
  16. package/components/block.d.ts +17 -4
  17. package/components/block.js +37 -11
  18. package/components/breadcrumbs-collapsed.js +2 -4
  19. package/components/breadcrumbs-item.js +2 -4
  20. package/components/breadcrumbs-separator.js +2 -2
  21. package/components/breadcrumbs.js +2 -2
  22. package/components/button.d.ts +3 -7
  23. package/components/button.js +8 -24
  24. package/components/card-content.js +2 -2
  25. package/components/card-footer.js +2 -2
  26. package/components/card-header.js +2 -2
  27. package/components/card.d.ts +5 -2
  28. package/components/card.js +14 -23
  29. package/components/checkbox.js +2 -4
  30. package/components/chip.d.ts +0 -1
  31. package/components/chip.js +2 -9
  32. package/components/fab-backdrop.js +2 -2
  33. package/components/fab-button.js +2 -6
  34. package/components/fab-buttons.js +2 -2
  35. package/components/fab.js +2 -10
  36. package/components/gauge.js +2 -2
  37. package/components/icon.d.ts +0 -1
  38. package/components/icon.js +3 -17
  39. package/components/input.js +1 -57
  40. package/components/link.d.ts +0 -1
  41. package/components/link.js +5 -12
  42. package/components/list-button.js +2 -4
  43. package/components/list-group.js +2 -2
  44. package/components/list-index.d.ts +0 -1
  45. package/components/list-index.js +3 -13
  46. package/components/list-input.d.ts +0 -1
  47. package/components/list-input.js +1 -55
  48. package/components/list-item-content.js +6 -20
  49. package/components/list-item.d.ts +0 -1
  50. package/components/list-item.js +5 -35
  51. package/components/list.d.ts +21 -9
  52. package/components/list.js +43 -37
  53. package/components/login-screen-title.js +2 -2
  54. package/components/login-screen.js +3 -15
  55. package/components/message.js +2 -10
  56. package/components/messagebar-attachment.js +2 -5
  57. package/components/messagebar-attachments.js +2 -2
  58. package/components/messagebar-sheet-image.js +4 -5
  59. package/components/messagebar-sheet-item.js +2 -2
  60. package/components/messagebar-sheet.js +2 -2
  61. package/components/messagebar.js +1 -19
  62. package/components/messages-title.js +2 -2
  63. package/components/messages.js +2 -15
  64. package/components/nav-left.js +2 -6
  65. package/components/nav-right.js +2 -2
  66. package/components/nav-title-large.js +2 -2
  67. package/components/nav-title.js +2 -4
  68. package/components/navbar.d.ts +1 -2
  69. package/components/navbar.js +5 -31
  70. package/components/page-content.js +2 -16
  71. package/components/page.d.ts +0 -1
  72. package/components/page.js +4 -62
  73. package/components/panel.d.ts +1 -0
  74. package/components/panel.js +6 -26
  75. package/components/photo-browser.js +1 -17
  76. package/components/pie-chart.js +6 -18
  77. package/components/popover.d.ts +1 -0
  78. package/components/popover.js +4 -14
  79. package/components/popup.js +3 -19
  80. package/components/preloader.js +5 -14
  81. package/components/progressbar.js +2 -4
  82. package/components/radio.js +2 -4
  83. package/components/range.js +2 -9
  84. package/components/routable-modals.js +2 -7
  85. package/components/searchbar.d.ts +1 -2
  86. package/components/searchbar.js +5 -30
  87. package/components/segmented.d.ts +0 -3
  88. package/components/segmented.js +4 -10
  89. package/components/sheet.js +2 -22
  90. package/components/stepper.d.ts +0 -5
  91. package/components/stepper.js +3 -33
  92. package/components/subnavbar.js +2 -2
  93. package/components/swipeout-actions.js +2 -4
  94. package/components/swipeout-button.js +2 -4
  95. package/components/swiper-slide.d.ts +1 -0
  96. package/components/swiper-slide.js +1 -0
  97. package/components/swiper.d.ts +1 -0
  98. package/components/swiper.js +1 -0
  99. package/components/tab.js +4 -15
  100. package/components/tabs.js +1 -4
  101. package/components/text-editor.js +1 -18
  102. package/components/toggle.js +1 -13
  103. package/components/toolbar.d.ts +2 -6
  104. package/components/toolbar.js +9 -20
  105. package/components/treeview-item.d.ts +0 -1
  106. package/components/treeview-item.js +2 -11
  107. package/components/treeview.js +2 -2
  108. package/components/view.d.ts +0 -6
  109. package/components/view.js +3 -30
  110. package/components/views.js +2 -2
  111. package/framework7-react.d.ts +2 -12
  112. package/framework7-react.js +3 -12
  113. package/package.json +1 -1
  114. package/shared/components-router.js +0 -32
  115. package/shared/f7.js +5 -19
  116. package/shared/get-router-initial-component.js +0 -4
  117. package/shared/mixins.js +2 -8
  118. package/shared/plugin.js +2 -8
  119. package/shared/router-open-in.js +4 -15
  120. package/shared/tabbar-context.js +1 -1
  121. package/shared/use-icon.js +1 -6
  122. package/shared/use-isomorphic-layout-effect.js +0 -2
  123. package/shared/use-route-props.js +0 -1
  124. package/shared/use-smart-select.js +0 -3
  125. package/shared/use-store.js +4 -8
  126. package/shared/use-tab.js +0 -4
  127. package/shared/use-theme.js +0 -2
  128. package/shared/use-tooltip.js +0 -5
  129. package/shared/utils.js +0 -18
  130. package/shared/watch-prop.js +0 -1
  131. package/components/appbar.d.ts +0 -28
  132. package/components/appbar.js +0 -45
  133. package/components/col.d.ts +0 -36
  134. package/components/col.js +0 -75
  135. package/components/list-item-cell.d.ts +0 -23
  136. package/components/list-item-cell.js +0 -28
  137. package/components/list-item-row.d.ts +0 -23
  138. package/components/list-item-row.js +0 -28
  139. package/components/menu-dropdown-item.d.ts +0 -68
  140. package/components/menu-dropdown-item.js +0 -59
  141. package/components/menu-dropdown.d.ts +0 -28
  142. package/components/menu-dropdown.js +0 -42
  143. package/components/menu-item.d.ts +0 -81
  144. package/components/menu-item.js +0 -101
  145. package/components/menu.d.ts +0 -23
  146. package/components/menu.js +0 -30
  147. package/components/row.d.ts +0 -31
  148. package/components/row.js +0 -64
@@ -1,5 +1,4 @@
1
- function _extends() { _extends = Object.assign || function (target) { for (var i = 1; i < arguments.length; i++) { var source = arguments[i]; for (var key in source) { if (Object.prototype.hasOwnProperty.call(source, key)) { target[key] = source[key]; } } } return target; }; return _extends.apply(this, arguments); }
2
-
1
+ function _extends() { _extends = Object.assign ? Object.assign.bind() : function (target) { for (var i = 1; i < arguments.length; i++) { var source = arguments[i]; for (var key in source) { if (Object.prototype.hasOwnProperty.call(source, key)) { target[key] = source[key]; } } } return target; }; return _extends.apply(this, arguments); }
3
2
  import React, { forwardRef, useRef, useImperativeHandle } from 'react';
4
3
  import { useIsomorphicLayoutEffect } from '../shared/use-isomorphic-layout-effect.js';
5
4
  import { classNames, getExtraAttrs, noUndefinedProps } from '../shared/utils.js';
@@ -8,6 +7,7 @@ import { f7ready, f7 } from '../shared/f7.js';
8
7
  import { watchProp } from '../shared/watch-prop.js';
9
8
 
10
9
 
10
+
11
11
  const Messages = /*#__PURE__*/forwardRef((props, ref) => {
12
12
  const f7Messages = useRef(null);
13
13
  const mounted = useRef(false);
@@ -41,7 +41,6 @@ const Messages = /*#__PURE__*/forwardRef((props, ref) => {
41
41
  el: elRef.current,
42
42
  f7Messages: () => f7Messages.current
43
43
  }));
44
-
45
44
  const onMount = () => {
46
45
  if (!init) return;
47
46
  f7ready(() => {
@@ -62,32 +61,26 @@ const Messages = /*#__PURE__*/forwardRef((props, ref) => {
62
61
  customClassMessageRule,
63
62
  renderMessage
64
63
  }));
65
-
66
64
  if (typing) {
67
65
  f7Messages.current.showTyping();
68
66
  }
69
67
  });
70
68
  };
71
-
72
69
  const onDestroy = () => {
73
70
  if (f7Messages.current && f7Messages.current.destroy) f7Messages.current.destroy();
74
71
  f7Messages.current = null;
75
72
  };
76
-
77
73
  useIsomorphicLayoutEffect(() => {
78
74
  onMount();
79
75
  return onDestroy;
80
76
  }, []);
81
77
  const currentChildrenLength = children ? React.Children.count(children) : 0;
82
-
83
78
  if (f7Messages.current && scrollMessages) {
84
79
  const beforeChildrenLength = reactChildrenBefore.current || 0;
85
-
86
80
  if (currentChildrenLength !== beforeChildrenLength) {
87
81
  f7Messages.current.setScrollData();
88
82
  }
89
83
  }
90
-
91
84
  reactChildrenBefore.current = currentChildrenLength;
92
85
  useIsomorphicLayoutEffect(() => {
93
86
  const wasMounted = mounted.current;
@@ -96,31 +89,25 @@ const Messages = /*#__PURE__*/forwardRef((props, ref) => {
96
89
  const childElements = elRef.current.children;
97
90
  if (!childElements) return;
98
91
  const childrenAfterUpdated = childElements.length;
99
-
100
92
  if (!wasMounted) {
101
93
  for (let i = 0; i < childElements.length; i += 1) {
102
94
  childElements[i].classList.add('message-appeared');
103
95
  }
104
-
105
96
  return;
106
97
  }
107
-
108
98
  for (let i = 0; i < childElements.length; i += 1) {
109
99
  if (!childElements[i].classList.contains('message-appeared')) {
110
100
  childElements[i].classList.add('message-appear-from-bottom');
111
101
  }
112
102
  }
113
-
114
103
  if (f7Messages.current) {
115
104
  if (f7Messages.current.layout && autoLayout) {
116
105
  f7Messages.current.layout();
117
106
  }
118
-
119
107
  if (childrenBeforeUpdated.current !== childrenAfterUpdated && f7Messages.current.scroll && f7Messages.current.scrollData && scrollMessages) {
120
108
  f7Messages.current.scrollWithEdgeCheck(true);
121
109
  }
122
110
  }
123
-
124
111
  childrenBeforeUpdated.current = childrenAfterUpdated;
125
112
  });
126
113
  watchProp(typing, newValue => {
@@ -1,11 +1,11 @@
1
- function _extends() { _extends = Object.assign || function (target) { for (var i = 1; i < arguments.length; i++) { var source = arguments[i]; for (var key in source) { if (Object.prototype.hasOwnProperty.call(source, key)) { target[key] = source[key]; } } } return target; }; return _extends.apply(this, arguments); }
2
-
1
+ function _extends() { _extends = Object.assign ? Object.assign.bind() : function (target) { for (var i = 1; i < arguments.length; i++) { var source = arguments[i]; for (var key in source) { if (Object.prototype.hasOwnProperty.call(source, key)) { target[key] = source[key]; } } } return target; }; return _extends.apply(this, arguments); }
3
2
  import React, { forwardRef, useRef, useImperativeHandle } from 'react';
4
3
  import { classNames, getExtraAttrs, emit } from '../shared/utils.js';
5
4
  import { colorClasses } from '../shared/mixins.js';
6
5
  import { useTheme } from '../shared/use-theme.js';
7
6
  import Link from './link.js';
8
7
 
8
+
9
9
  const NavLeft = /*#__PURE__*/forwardRef((props, ref) => {
10
10
  const {
11
11
  className,
@@ -20,11 +20,9 @@ const NavLeft = /*#__PURE__*/forwardRef((props, ref) => {
20
20
  } = props;
21
21
  const extraAttrs = getExtraAttrs(props);
22
22
  const elRef = useRef(null);
23
-
24
23
  const onBackClick = event => {
25
24
  emit(props, 'backClick clickBack', event);
26
25
  };
27
-
28
26
  useImperativeHandle(ref, () => ({
29
27
  el: elRef.current
30
28
  }));
@@ -32,7 +30,6 @@ const NavLeft = /*#__PURE__*/forwardRef((props, ref) => {
32
30
  let linkEl;
33
31
  let needBackLinkText = backLinkShowText;
34
32
  if (typeof needBackLinkText === 'undefined') needBackLinkText = !theme.md;
35
-
36
33
  if (backLink) {
37
34
  const text = backLink !== true && needBackLinkText ? backLink : undefined;
38
35
  linkEl = /*#__PURE__*/React.createElement(Link, {
@@ -45,7 +42,6 @@ const NavLeft = /*#__PURE__*/forwardRef((props, ref) => {
45
42
  onClick: onBackClick
46
43
  });
47
44
  }
48
-
49
45
  const classes = classNames(className, 'left', {
50
46
  sliding
51
47
  }, colorClasses(props));
@@ -1,9 +1,9 @@
1
- function _extends() { _extends = Object.assign || function (target) { for (var i = 1; i < arguments.length; i++) { var source = arguments[i]; for (var key in source) { if (Object.prototype.hasOwnProperty.call(source, key)) { target[key] = source[key]; } } } return target; }; return _extends.apply(this, arguments); }
2
-
1
+ function _extends() { _extends = Object.assign ? Object.assign.bind() : function (target) { for (var i = 1; i < arguments.length; i++) { var source = arguments[i]; for (var key in source) { if (Object.prototype.hasOwnProperty.call(source, key)) { target[key] = source[key]; } } } return target; }; return _extends.apply(this, arguments); }
3
2
  import React, { forwardRef, useRef, useImperativeHandle } from 'react';
4
3
  import { classNames, getExtraAttrs } from '../shared/utils.js';
5
4
  import { colorClasses } from '../shared/mixins.js';
6
5
 
6
+
7
7
  const NavRight = /*#__PURE__*/forwardRef((props, ref) => {
8
8
  const {
9
9
  className,
@@ -1,9 +1,9 @@
1
- function _extends() { _extends = Object.assign || function (target) { for (var i = 1; i < arguments.length; i++) { var source = arguments[i]; for (var key in source) { if (Object.prototype.hasOwnProperty.call(source, key)) { target[key] = source[key]; } } } return target; }; return _extends.apply(this, arguments); }
2
-
1
+ function _extends() { _extends = Object.assign ? Object.assign.bind() : function (target) { for (var i = 1; i < arguments.length; i++) { var source = arguments[i]; for (var key in source) { if (Object.prototype.hasOwnProperty.call(source, key)) { target[key] = source[key]; } } } return target; }; return _extends.apply(this, arguments); }
3
2
  import React, { forwardRef, useRef, useImperativeHandle } from 'react';
4
3
  import { classNames, getExtraAttrs } from '../shared/utils.js';
5
4
  import { colorClasses } from '../shared/mixins.js';
6
5
 
6
+
7
7
  const NavTitleLarge = /*#__PURE__*/forwardRef((props, ref) => {
8
8
  const {
9
9
  className,
@@ -1,9 +1,9 @@
1
- function _extends() { _extends = Object.assign || function (target) { for (var i = 1; i < arguments.length; i++) { var source = arguments[i]; for (var key in source) { if (Object.prototype.hasOwnProperty.call(source, key)) { target[key] = source[key]; } } } return target; }; return _extends.apply(this, arguments); }
2
-
1
+ function _extends() { _extends = Object.assign ? Object.assign.bind() : function (target) { for (var i = 1; i < arguments.length; i++) { var source = arguments[i]; for (var key in source) { if (Object.prototype.hasOwnProperty.call(source, key)) { target[key] = source[key]; } } } return target; }; return _extends.apply(this, arguments); }
3
2
  import React, { forwardRef, useRef, useImperativeHandle } from 'react';
4
3
  import { classNames, getExtraAttrs } from '../shared/utils.js';
5
4
  import { colorClasses } from '../shared/mixins.js';
6
5
 
6
+
7
7
  const NavTitle = /*#__PURE__*/forwardRef((props, ref) => {
8
8
  const {
9
9
  className,
@@ -20,13 +20,11 @@ const NavTitle = /*#__PURE__*/forwardRef((props, ref) => {
20
20
  el: elRef.current
21
21
  }));
22
22
  let subtitleEl;
23
-
24
23
  if (subtitle) {
25
24
  subtitleEl = /*#__PURE__*/React.createElement("span", {
26
25
  className: "subtitle"
27
26
  }, subtitle);
28
27
  }
29
-
30
28
  const classes = classNames(className, 'title', {
31
29
  sliding
32
30
  }, colorClasses(props));
@@ -15,8 +15,7 @@ export interface NavbarProps {
15
15
  title ?: string;
16
16
  subtitle ?: string;
17
17
  hidden ?: boolean;
18
- noShadow ?: boolean;
19
- noHairline ?: boolean;
18
+ outline ?: boolean;
20
19
  innerClass ?: string;
21
20
  innerClassName ?: string;
22
21
  large ?: boolean;
@@ -1,5 +1,4 @@
1
- function _extends() { _extends = Object.assign || function (target) { for (var i = 1; i < arguments.length; i++) { var source = arguments[i]; for (var key in source) { if (Object.prototype.hasOwnProperty.call(source, key)) { target[key] = source[key]; } } } return target; }; return _extends.apply(this, arguments); }
2
-
1
+ function _extends() { _extends = Object.assign ? Object.assign.bind() : function (target) { for (var i = 1; i < arguments.length; i++) { var source = arguments[i]; for (var key in source) { if (Object.prototype.hasOwnProperty.call(source, key)) { target[key] = source[key]; } } } return target; }; return _extends.apply(this, arguments); }
3
2
  import React, { forwardRef, useRef, useImperativeHandle } from 'react';
4
3
  import { useIsomorphicLayoutEffect } from '../shared/use-isomorphic-layout-effect.js';
5
4
  import { classNames, getExtraAttrs, emit, getSlots } from '../shared/utils.js';
@@ -10,6 +9,7 @@ import NavLeft from './nav-left.js';
10
9
  import NavTitle from './nav-title.js';
11
10
  import NavRight from './nav-right.js';
12
11
 
12
+
13
13
  const Navbar = /*#__PURE__*/forwardRef((props, ref) => {
14
14
  const {
15
15
  className,
@@ -20,8 +20,7 @@ const Navbar = /*#__PURE__*/forwardRef((props, ref) => {
20
20
  largeTransparent,
21
21
  transparent,
22
22
  hidden,
23
- noShadow,
24
- noHairline,
23
+ outline = true,
25
24
  backLink,
26
25
  backLinkForce,
27
26
  backLinkUrl,
@@ -41,88 +40,72 @@ const Navbar = /*#__PURE__*/forwardRef((props, ref) => {
41
40
  const extraAttrs = getExtraAttrs(props);
42
41
  const elRef = useRef(null);
43
42
  const theme = useTheme();
44
-
45
43
  const onHide = navbarEl => {
46
44
  if (elRef.current !== navbarEl) return;
47
45
  emit(props, 'navbarHide');
48
46
  };
49
-
50
47
  const onShow = navbarEl => {
51
48
  if (elRef.current !== navbarEl) return;
52
49
  emit(props, 'navbarShow');
53
50
  };
54
-
55
51
  const onExpand = navbarEl => {
56
52
  if (elRef.current !== navbarEl) return;
57
53
  largeCollapsed.current = false;
58
54
  emit(props, 'navbarExpand');
59
55
  };
60
-
61
56
  const onCollapse = navbarEl => {
62
57
  if (elRef.current !== navbarEl) return;
63
58
  largeCollapsed.current = true;
64
59
  emit(props, 'navbarCollapse');
65
60
  };
66
-
67
61
  const onNavbarTransparentShow = navbarEl => {
68
62
  if (elRef.current !== navbarEl) return;
69
63
  transparentVisible.current = true;
70
64
  emit(props, 'navbarTransparentShow');
71
65
  };
72
-
73
66
  const onNavbarTransparentHide = navbarEl => {
74
67
  if (elRef.current !== navbarEl) return;
75
68
  transparentVisible.current = false;
76
69
  emit(props, 'navbarTransparentHide');
77
70
  };
78
-
79
71
  const onNavbarPosition = (navbarEl, position) => {
80
72
  if (elRef.current !== navbarEl) return;
81
73
  routerPositionClass.current = position ? `navbar-${position}` : '';
82
74
  };
83
-
84
75
  const onNavbarRole = (navbarEl, rolesData) => {
85
76
  if (elRef.current !== navbarEl) return;
86
77
  routerNavbarRole.current = rolesData.role;
87
78
  routerNavbarRoleDetailRoot.current = rolesData.detailRoot;
88
79
  };
89
-
90
80
  const onNavbarMasterStack = navbarEl => {
91
81
  if (elRef.current !== navbarEl) return;
92
82
  routerNavbarMasterStack.current = true;
93
83
  };
94
-
95
84
  const onNavbarMasterUnstack = navbarEl => {
96
85
  if (elRef.current !== navbarEl) return;
97
86
  routerNavbarMasterStack.current = false;
98
87
  };
99
-
100
88
  const hide = animate => {
101
89
  if (!f7) return;
102
90
  f7.navbar.hide(elRef.current, animate);
103
91
  };
104
-
105
92
  const show = animate => {
106
93
  if (!f7) return;
107
94
  f7.navbar.show(elRef.current, animate);
108
95
  };
109
-
110
96
  const size = () => {
111
97
  if (!f7) return;
112
98
  f7.navbar.size(elRef.current);
113
99
  };
114
-
115
100
  const onBackClick = event => {
116
101
  emit(props, 'backClick clickBack', event);
117
102
  };
118
-
119
103
  useImperativeHandle(ref, () => ({
120
104
  el: elRef.current,
121
105
  hide,
122
106
  show,
123
107
  size
124
108
  }));
125
-
126
109
  const attachEvents = () => {
127
110
  if (!elRef.current) return;
128
111
  f7ready(() => {
@@ -139,7 +122,6 @@ const Navbar = /*#__PURE__*/forwardRef((props, ref) => {
139
122
  f7.on('navbarTransparentHide', onNavbarTransparentHide);
140
123
  });
141
124
  };
142
-
143
125
  const detachEvents = () => {
144
126
  if (!f7) return;
145
127
  f7.off('navbarShow', onShow);
@@ -153,7 +135,6 @@ const Navbar = /*#__PURE__*/forwardRef((props, ref) => {
153
135
  f7.off('navbarTransparentShow', onNavbarTransparentShow);
154
136
  f7.off('navbarTransparentHide', onNavbarTransparentHide);
155
137
  };
156
-
157
138
  useIsomorphicLayoutEffect(() => {
158
139
  attachEvents();
159
140
  return detachEvents;
@@ -164,7 +145,7 @@ const Navbar = /*#__PURE__*/forwardRef((props, ref) => {
164
145
  let rightEl;
165
146
  let titleLargeEl;
166
147
  const addLeftTitleClass = theme && theme.ios && f7 && !f7.params.navbar.iosCenterTitle;
167
- const addCenterTitleClass = theme && theme.md && f7 && f7.params.navbar.mdCenterTitle || theme && theme.aurora && f7 && f7.params.navbar.auroraCenterTitle;
148
+ const addCenterTitleClass = theme && theme.md && f7 && f7.params.navbar.mdCenterTitle;
168
149
  const isLarge = large || largeTransparent;
169
150
  const isTransparent = transparent || isLarge && largeTransparent;
170
151
  const isTransparentVisible = isTransparent && transparentVisible.current;
@@ -178,10 +159,8 @@ const Navbar = /*#__PURE__*/forwardRef((props, ref) => {
178
159
  'navbar-master-detail': routerNavbarRole.current === 'detail',
179
160
  'navbar-master-detail-root': routerNavbarRoleDetailRoot.current === true,
180
161
  'navbar-master-stacked': routerNavbarMasterStack.current === true,
181
- 'no-shadow': noShadow,
182
- 'no-hairline': noHairline
162
+ 'no-outline': !outline
183
163
  }, colorClasses(props));
184
-
185
164
  if (backLink || slots['nav-left'] || slots.left) {
186
165
  leftEl = /*#__PURE__*/React.createElement(NavLeft, {
187
166
  backLink: backLink,
@@ -191,21 +170,17 @@ const Navbar = /*#__PURE__*/forwardRef((props, ref) => {
191
170
  onBackClick: onBackClick
192
171
  }, slots['nav-left'], slots.left);
193
172
  }
194
-
195
173
  if (title || subtitle || slots.title) {
196
174
  titleEl = /*#__PURE__*/React.createElement(NavTitle, {
197
175
  title: title,
198
176
  subtitle: subtitle
199
177
  }, slots.title);
200
178
  }
201
-
202
179
  if (slots['nav-right'] || slots.right) {
203
180
  rightEl = /*#__PURE__*/React.createElement(NavRight, null, slots['nav-right'], slots.right);
204
181
  }
205
-
206
182
  let largeTitle = titleLarge;
207
183
  if (!largeTitle && large && title) largeTitle = title;
208
-
209
184
  if (largeTitle || slots['title-large']) {
210
185
  titleLargeEl = /*#__PURE__*/React.createElement("div", {
211
186
  className: "title-large"
@@ -213,7 +188,6 @@ const Navbar = /*#__PURE__*/forwardRef((props, ref) => {
213
188
  className: "title-large-text"
214
189
  }, largeTitle || '', slots['title-large']));
215
190
  }
216
-
217
191
  const innerEl = /*#__PURE__*/React.createElement("div", {
218
192
  className: classNames('navbar-inner', innerClass, innerClassName, {
219
193
  sliding,
@@ -1,5 +1,4 @@
1
- function _extends() { _extends = Object.assign || function (target) { for (var i = 1; i < arguments.length; i++) { var source = arguments[i]; for (var key in source) { if (Object.prototype.hasOwnProperty.call(source, key)) { target[key] = source[key]; } } } return target; }; return _extends.apply(this, arguments); }
2
-
1
+ function _extends() { _extends = Object.assign ? Object.assign.bind() : function (target) { for (var i = 1; i < arguments.length; i++) { var source = arguments[i]; for (var key in source) { if (Object.prototype.hasOwnProperty.call(source, key)) { target[key] = source[key]; } } } return target; }; return _extends.apply(this, arguments); }
3
2
  import React, { forwardRef, useRef, useImperativeHandle } from 'react';
4
3
  import { useIsomorphicLayoutEffect } from '../shared/use-isomorphic-layout-effect.js';
5
4
  import { classNames, getExtraAttrs, emit } from '../shared/utils.js';
@@ -8,6 +7,7 @@ import Preloader from './preloader.js';
8
7
  import { useTab } from '../shared/use-tab.js';
9
8
  import { f7ready, f7 } from '../shared/f7.js';
10
9
 
10
+
11
11
  const PageContent = /*#__PURE__*/forwardRef((props, ref) => {
12
12
  const {
13
13
  className,
@@ -33,42 +33,34 @@ const PageContent = /*#__PURE__*/forwardRef((props, ref) => {
33
33
  } = props;
34
34
  const extraAttrs = getExtraAttrs(props);
35
35
  const elRef = useRef(null);
36
-
37
36
  const onPtrPullStart = el => {
38
37
  if (elRef.current !== el) return;
39
38
  emit(props, 'ptrPullStart');
40
39
  };
41
-
42
40
  const onPtrPullMove = el => {
43
41
  if (elRef.current !== el) return;
44
42
  emit(props, 'ptrPullMove');
45
43
  };
46
-
47
44
  const onPtrPullEnd = el => {
48
45
  if (elRef.current !== el) return;
49
46
  emit(props, 'ptrPullEnd');
50
47
  };
51
-
52
48
  const onPtrRefresh = (el, done) => {
53
49
  if (elRef.current !== el) return;
54
50
  emit(props, 'ptrRefresh', done);
55
51
  };
56
-
57
52
  const onPtrDone = el => {
58
53
  if (elRef.current !== el) return;
59
54
  emit(props, 'ptrDone');
60
55
  };
61
-
62
56
  const onInfinite = el => {
63
57
  if (elRef.current !== el) return;
64
58
  emit(props, 'infinite');
65
59
  };
66
-
67
60
  useImperativeHandle(ref, () => ({
68
61
  el: elRef.current
69
62
  }));
70
63
  useTab(elRef, props);
71
-
72
64
  const attachEvents = () => {
73
65
  f7ready(() => {
74
66
  if (ptr) {
@@ -78,13 +70,11 @@ const PageContent = /*#__PURE__*/forwardRef((props, ref) => {
78
70
  f7.on('ptrRefresh', onPtrRefresh);
79
71
  f7.on('ptrDone', onPtrDone);
80
72
  }
81
-
82
73
  if (infinite) {
83
74
  f7.on('infinite', onInfinite);
84
75
  }
85
76
  });
86
77
  };
87
-
88
78
  const detachEvents = () => {
89
79
  if (!f7) return;
90
80
  f7.off('ptrPullStart', onPtrPullStart);
@@ -94,14 +84,12 @@ const PageContent = /*#__PURE__*/forwardRef((props, ref) => {
94
84
  f7.off('ptrDone', onPtrDone);
95
85
  f7.off('infinite', onInfinite);
96
86
  };
97
-
98
87
  useIsomorphicLayoutEffect(() => {
99
88
  attachEvents();
100
89
  return detachEvents;
101
90
  });
102
91
  let ptrEl;
103
92
  let infiniteEl;
104
-
105
93
  if (ptr && ptrPreloader) {
106
94
  ptrEl = /*#__PURE__*/React.createElement("div", {
107
95
  className: "ptr-preloader"
@@ -109,13 +97,11 @@ const PageContent = /*#__PURE__*/forwardRef((props, ref) => {
109
97
  className: "ptr-arrow"
110
98
  }));
111
99
  }
112
-
113
100
  if (infinite && infinitePreloader) {
114
101
  infiniteEl = /*#__PURE__*/React.createElement(Preloader, {
115
102
  className: "infinite-scroll-preloader"
116
103
  });
117
104
  }
118
-
119
105
  const classes = classNames(className, 'page-content', {
120
106
  tab,
121
107
  'tab-active': tabActive,
@@ -8,7 +8,6 @@ export interface PageProps {
8
8
  className?: string;
9
9
  style?: React.CSSProperties;
10
10
  name ?: string;
11
- stacked ?: boolean;
12
11
  withSubnavbar ?: boolean;
13
12
  subnavbar ?: boolean;
14
13
  withNavbarLarge ?: boolean;