@workday/canvas-kit-labs-react 5.3.0 → 5.3.4

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 (223) hide show
  1. package/common/lib/theming/index.ts +0 -1
  2. package/dist/commonjs/common/lib/theming/index.d.ts +0 -1
  3. package/dist/commonjs/common/lib/theming/index.d.ts.map +1 -1
  4. package/dist/commonjs/common/lib/theming/index.js +0 -1
  5. package/dist/commonjs/header/index.d.ts +5 -5
  6. package/dist/commonjs/header/index.d.ts.map +1 -1
  7. package/dist/commonjs/header/index.js +2 -2
  8. package/dist/commonjs/header/lib/GlobalHeader.d.ts +2 -11
  9. package/dist/commonjs/header/lib/GlobalHeader.d.ts.map +1 -1
  10. package/dist/commonjs/header/lib/GlobalHeader.js +8 -19
  11. package/dist/commonjs/header/lib/Header.d.ts +8 -17
  12. package/dist/commonjs/header/lib/Header.d.ts.map +1 -1
  13. package/dist/commonjs/header/lib/Header.js +14 -27
  14. package/dist/commonjs/header/lib/parts/DubLogoTitle.d.ts +4 -13
  15. package/dist/commonjs/header/lib/parts/DubLogoTitle.d.ts.map +1 -1
  16. package/dist/commonjs/header/lib/parts/DubLogoTitle.js +11 -22
  17. package/dist/commonjs/{search-form/lib/SearchForm.d.ts → header/lib/parts/SearchBar.d.ts} +23 -22
  18. package/dist/commonjs/header/lib/parts/SearchBar.d.ts.map +1 -0
  19. package/dist/commonjs/{search-form/lib/SearchForm.js → header/lib/parts/SearchBar.js} +14 -13
  20. package/dist/commonjs/header/lib/parts/WorkdayLogoTitle.d.ts +5 -14
  21. package/dist/commonjs/header/lib/parts/WorkdayLogoTitle.d.ts.map +1 -1
  22. package/dist/commonjs/header/lib/parts/WorkdayLogoTitle.js +12 -25
  23. package/dist/commonjs/header/lib/parts/index.d.ts +3 -2
  24. package/dist/commonjs/header/lib/parts/index.d.ts.map +1 -1
  25. package/dist/commonjs/header/lib/parts/index.js +4 -2
  26. package/dist/commonjs/header/lib/shared/themes.d.ts +19 -28
  27. package/dist/commonjs/header/lib/shared/themes.d.ts.map +1 -1
  28. package/dist/commonjs/header/lib/shared/themes.js +36 -13
  29. package/dist/commonjs/header/lib/shared/types.d.ts +8 -3
  30. package/dist/commonjs/header/lib/shared/types.d.ts.map +1 -1
  31. package/dist/commonjs/header/lib/shared/types.js +23 -17
  32. package/dist/commonjs/index.d.ts +0 -2
  33. package/dist/commonjs/index.d.ts.map +1 -1
  34. package/dist/commonjs/index.js +0 -2
  35. package/dist/commonjs/layout/lib/utils/getValidChildren.d.ts +1 -1
  36. package/dist/commonjs/layout/lib/utils/getValidChildren.d.ts.map +1 -1
  37. package/dist/es6/common/lib/theming/index.d.ts +0 -1
  38. package/dist/es6/common/lib/theming/index.d.ts.map +1 -1
  39. package/dist/es6/common/lib/theming/index.js +0 -1
  40. package/dist/es6/header/index.d.ts +5 -5
  41. package/dist/es6/header/index.d.ts.map +1 -1
  42. package/dist/es6/header/index.js +5 -5
  43. package/dist/es6/header/lib/GlobalHeader.d.ts +2 -11
  44. package/dist/es6/header/lib/GlobalHeader.d.ts.map +1 -1
  45. package/dist/es6/header/lib/GlobalHeader.js +11 -22
  46. package/dist/es6/header/lib/Header.d.ts +8 -17
  47. package/dist/es6/header/lib/Header.d.ts.map +1 -1
  48. package/dist/es6/header/lib/Header.js +17 -30
  49. package/dist/es6/header/lib/parts/DubLogoTitle.d.ts +4 -13
  50. package/dist/es6/header/lib/parts/DubLogoTitle.d.ts.map +1 -1
  51. package/dist/es6/header/lib/parts/DubLogoTitle.js +12 -23
  52. package/dist/es6/{search-form/lib/SearchForm.d.ts → header/lib/parts/SearchBar.d.ts} +23 -22
  53. package/dist/es6/header/lib/parts/SearchBar.d.ts.map +1 -0
  54. package/dist/es6/{search-form/lib/SearchForm.js → header/lib/parts/SearchBar.js} +12 -11
  55. package/dist/es6/header/lib/parts/WorkdayLogoTitle.d.ts +5 -14
  56. package/dist/es6/header/lib/parts/WorkdayLogoTitle.d.ts.map +1 -1
  57. package/dist/es6/header/lib/parts/WorkdayLogoTitle.js +13 -26
  58. package/dist/es6/header/lib/parts/index.d.ts +3 -2
  59. package/dist/es6/header/lib/parts/index.d.ts.map +1 -1
  60. package/dist/es6/header/lib/parts/index.js +3 -2
  61. package/dist/es6/header/lib/shared/themes.d.ts +19 -28
  62. package/dist/es6/header/lib/shared/themes.d.ts.map +1 -1
  63. package/dist/es6/header/lib/shared/themes.js +37 -14
  64. package/dist/es6/header/lib/shared/types.d.ts +8 -3
  65. package/dist/es6/header/lib/shared/types.d.ts.map +1 -1
  66. package/dist/es6/header/lib/shared/types.js +23 -17
  67. package/dist/es6/index.d.ts +0 -2
  68. package/dist/es6/index.d.ts.map +1 -1
  69. package/dist/es6/index.js +0 -2
  70. package/dist/es6/layout/lib/utils/getValidChildren.d.ts +1 -1
  71. package/dist/es6/layout/lib/utils/getValidChildren.d.ts.map +1 -1
  72. package/header/README.md +181 -37
  73. package/header/index.ts +5 -5
  74. package/header/lib/GlobalHeader.tsx +9 -26
  75. package/header/lib/Header.tsx +26 -58
  76. package/header/lib/parts/DubLogoTitle.tsx +9 -26
  77. package/{search-form/lib/SearchForm.tsx → header/lib/parts/SearchBar.tsx} +31 -30
  78. package/header/lib/parts/WorkdayLogoTitle.tsx +11 -40
  79. package/header/lib/parts/index.ts +3 -2
  80. package/header/lib/shared/themes.tsx +56 -32
  81. package/header/lib/shared/types.tsx +9 -3
  82. package/index.ts +0 -2
  83. package/package.json +5 -7
  84. package/ts3.5/dist/commonjs/common/lib/theming/index.d.ts +0 -1
  85. package/ts3.5/dist/commonjs/header/index.d.ts +5 -5
  86. package/ts3.5/dist/commonjs/header/lib/GlobalHeader.d.ts +2 -11
  87. package/ts3.5/dist/commonjs/header/lib/Header.d.ts +8 -17
  88. package/ts3.5/dist/commonjs/header/lib/parts/DubLogoTitle.d.ts +4 -13
  89. package/ts3.5/dist/{es6/search-form/lib/SearchForm.d.ts → commonjs/header/lib/parts/SearchBar.d.ts} +23 -22
  90. package/ts3.5/dist/commonjs/header/lib/parts/WorkdayLogoTitle.d.ts +5 -14
  91. package/ts3.5/dist/commonjs/header/lib/parts/index.d.ts +3 -2
  92. package/ts3.5/dist/commonjs/header/lib/shared/themes.d.ts +19 -28
  93. package/ts3.5/dist/commonjs/header/lib/shared/types.d.ts +8 -3
  94. package/ts3.5/dist/commonjs/index.d.ts +0 -2
  95. package/ts3.5/dist/commonjs/layout/lib/utils/getValidChildren.d.ts +1 -1
  96. package/ts3.5/dist/es6/common/lib/theming/index.d.ts +0 -1
  97. package/ts3.5/dist/es6/header/index.d.ts +5 -5
  98. package/ts3.5/dist/es6/header/lib/GlobalHeader.d.ts +2 -11
  99. package/ts3.5/dist/es6/header/lib/Header.d.ts +8 -17
  100. package/ts3.5/dist/es6/header/lib/parts/DubLogoTitle.d.ts +4 -13
  101. package/ts3.5/dist/{commonjs/search-form/lib/SearchForm.d.ts → es6/header/lib/parts/SearchBar.d.ts} +23 -22
  102. package/ts3.5/dist/es6/header/lib/parts/WorkdayLogoTitle.d.ts +5 -14
  103. package/ts3.5/dist/es6/header/lib/parts/index.d.ts +3 -2
  104. package/ts3.5/dist/es6/header/lib/shared/themes.d.ts +19 -28
  105. package/ts3.5/dist/es6/header/lib/shared/types.d.ts +8 -3
  106. package/ts3.5/dist/es6/index.d.ts +0 -2
  107. package/ts3.5/dist/es6/layout/lib/utils/getValidChildren.d.ts +1 -1
  108. package/common/lib/theming/useThemedRing.ts +0 -84
  109. package/dist/commonjs/common/lib/theming/useThemedRing.d.ts +0 -11
  110. package/dist/commonjs/common/lib/theming/useThemedRing.d.ts.map +0 -1
  111. package/dist/commonjs/common/lib/theming/useThemedRing.js +0 -61
  112. package/dist/commonjs/search-form/index.d.ts +0 -3
  113. package/dist/commonjs/search-form/index.d.ts.map +0 -1
  114. package/dist/commonjs/search-form/index.js +0 -7
  115. package/dist/commonjs/search-form/lib/SearchForm.d.ts.map +0 -1
  116. package/dist/commonjs/search-form/lib/themes.d.ts +0 -21
  117. package/dist/commonjs/search-form/lib/themes.d.ts.map +0 -1
  118. package/dist/commonjs/search-form/lib/themes.js +0 -41
  119. package/dist/commonjs/text-input/index.d.ts +0 -7
  120. package/dist/commonjs/text-input/index.d.ts.map +0 -1
  121. package/dist/commonjs/text-input/index.js +0 -11
  122. package/dist/commonjs/text-input/lib/TextInput.d.ts +0 -21
  123. package/dist/commonjs/text-input/lib/TextInput.d.ts.map +0 -1
  124. package/dist/commonjs/text-input/lib/TextInput.js +0 -36
  125. package/dist/commonjs/text-input/lib/TextInputField.d.ts +0 -8
  126. package/dist/commonjs/text-input/lib/TextInputField.d.ts.map +0 -1
  127. package/dist/commonjs/text-input/lib/TextInputField.js +0 -66
  128. package/dist/commonjs/text-input/lib/TextInputHint.d.ts +0 -13
  129. package/dist/commonjs/text-input/lib/TextInputHint.d.ts.map +0 -1
  130. package/dist/commonjs/text-input/lib/TextInputHint.js +0 -46
  131. package/dist/commonjs/text-input/lib/TextInputLabel.d.ts +0 -17
  132. package/dist/commonjs/text-input/lib/TextInputLabel.d.ts.map +0 -1
  133. package/dist/commonjs/text-input/lib/TextInputLabel.js +0 -54
  134. package/dist/commonjs/text-input/lib/hooks/useTextInputField.d.ts +0 -19
  135. package/dist/commonjs/text-input/lib/hooks/useTextInputField.d.ts.map +0 -1
  136. package/dist/commonjs/text-input/lib/hooks/useTextInputField.js +0 -16
  137. package/dist/commonjs/text-input/lib/hooks/useTextInputHint.d.ts +0 -15
  138. package/dist/commonjs/text-input/lib/hooks/useTextInputHint.d.ts.map +0 -1
  139. package/dist/commonjs/text-input/lib/hooks/useTextInputHint.js +0 -12
  140. package/dist/commonjs/text-input/lib/hooks/useTextInputLabel.d.ts +0 -15
  141. package/dist/commonjs/text-input/lib/hooks/useTextInputLabel.d.ts.map +0 -1
  142. package/dist/commonjs/text-input/lib/hooks/useTextInputLabel.js +0 -12
  143. package/dist/commonjs/text-input/lib/hooks/useTextInputModel.d.ts +0 -17
  144. package/dist/commonjs/text-input/lib/hooks/useTextInputModel.d.ts.map +0 -1
  145. package/dist/commonjs/text-input/lib/hooks/useTextInputModel.js +0 -23
  146. package/dist/es6/common/lib/theming/useThemedRing.d.ts +0 -11
  147. package/dist/es6/common/lib/theming/useThemedRing.d.ts.map +0 -1
  148. package/dist/es6/common/lib/theming/useThemedRing.js +0 -55
  149. package/dist/es6/search-form/index.d.ts +0 -3
  150. package/dist/es6/search-form/index.d.ts.map +0 -1
  151. package/dist/es6/search-form/index.js +0 -2
  152. package/dist/es6/search-form/lib/SearchForm.d.ts.map +0 -1
  153. package/dist/es6/search-form/lib/themes.d.ts +0 -21
  154. package/dist/es6/search-form/lib/themes.d.ts.map +0 -1
  155. package/dist/es6/search-form/lib/themes.js +0 -39
  156. package/dist/es6/text-input/index.d.ts +0 -7
  157. package/dist/es6/text-input/index.d.ts.map +0 -1
  158. package/dist/es6/text-input/index.js +0 -6
  159. package/dist/es6/text-input/lib/TextInput.d.ts +0 -21
  160. package/dist/es6/text-input/lib/TextInput.d.ts.map +0 -1
  161. package/dist/es6/text-input/lib/TextInput.js +0 -31
  162. package/dist/es6/text-input/lib/TextInputField.d.ts +0 -8
  163. package/dist/es6/text-input/lib/TextInputField.d.ts.map +0 -1
  164. package/dist/es6/text-input/lib/TextInputField.js +0 -64
  165. package/dist/es6/text-input/lib/TextInputHint.d.ts +0 -13
  166. package/dist/es6/text-input/lib/TextInputHint.d.ts.map +0 -1
  167. package/dist/es6/text-input/lib/TextInputHint.js +0 -44
  168. package/dist/es6/text-input/lib/TextInputLabel.d.ts +0 -17
  169. package/dist/es6/text-input/lib/TextInputLabel.d.ts.map +0 -1
  170. package/dist/es6/text-input/lib/TextInputLabel.js +0 -52
  171. package/dist/es6/text-input/lib/hooks/useTextInputField.d.ts +0 -19
  172. package/dist/es6/text-input/lib/hooks/useTextInputField.d.ts.map +0 -1
  173. package/dist/es6/text-input/lib/hooks/useTextInputField.js +0 -14
  174. package/dist/es6/text-input/lib/hooks/useTextInputHint.d.ts +0 -15
  175. package/dist/es6/text-input/lib/hooks/useTextInputHint.d.ts.map +0 -1
  176. package/dist/es6/text-input/lib/hooks/useTextInputHint.js +0 -10
  177. package/dist/es6/text-input/lib/hooks/useTextInputLabel.d.ts +0 -15
  178. package/dist/es6/text-input/lib/hooks/useTextInputLabel.d.ts.map +0 -1
  179. package/dist/es6/text-input/lib/hooks/useTextInputLabel.js +0 -10
  180. package/dist/es6/text-input/lib/hooks/useTextInputModel.d.ts +0 -17
  181. package/dist/es6/text-input/lib/hooks/useTextInputModel.d.ts.map +0 -1
  182. package/dist/es6/text-input/lib/hooks/useTextInputModel.js +0 -21
  183. package/search-form/LICENSE +0 -52
  184. package/search-form/README.md +0 -6
  185. package/search-form/index.ts +0 -2
  186. package/search-form/lib/themes.ts +0 -54
  187. package/search-form/package.json +0 -5
  188. package/text-input/LICENSE +0 -52
  189. package/text-input/README.md +0 -11
  190. package/text-input/index.ts +0 -6
  191. package/text-input/lib/TextInput.tsx +0 -34
  192. package/text-input/lib/TextInputField.tsx +0 -75
  193. package/text-input/lib/TextInputHint.tsx +0 -52
  194. package/text-input/lib/TextInputLabel.tsx +0 -74
  195. package/text-input/lib/hooks/useTextInputField.tsx +0 -15
  196. package/text-input/lib/hooks/useTextInputHint.tsx +0 -11
  197. package/text-input/lib/hooks/useTextInputLabel.tsx +0 -11
  198. package/text-input/lib/hooks/useTextInputModel.tsx +0 -45
  199. package/text-input/package.json +0 -5
  200. package/ts3.5/dist/commonjs/common/lib/theming/useThemedRing.d.ts +0 -11
  201. package/ts3.5/dist/commonjs/search-form/index.d.ts +0 -3
  202. package/ts3.5/dist/commonjs/search-form/lib/themes.d.ts +0 -21
  203. package/ts3.5/dist/commonjs/text-input/index.d.ts +0 -7
  204. package/ts3.5/dist/commonjs/text-input/lib/TextInput.d.ts +0 -21
  205. package/ts3.5/dist/commonjs/text-input/lib/TextInputField.d.ts +0 -8
  206. package/ts3.5/dist/commonjs/text-input/lib/TextInputHint.d.ts +0 -13
  207. package/ts3.5/dist/commonjs/text-input/lib/TextInputLabel.d.ts +0 -17
  208. package/ts3.5/dist/commonjs/text-input/lib/hooks/useTextInputField.d.ts +0 -19
  209. package/ts3.5/dist/commonjs/text-input/lib/hooks/useTextInputHint.d.ts +0 -15
  210. package/ts3.5/dist/commonjs/text-input/lib/hooks/useTextInputLabel.d.ts +0 -15
  211. package/ts3.5/dist/commonjs/text-input/lib/hooks/useTextInputModel.d.ts +0 -17
  212. package/ts3.5/dist/es6/common/lib/theming/useThemedRing.d.ts +0 -11
  213. package/ts3.5/dist/es6/search-form/index.d.ts +0 -3
  214. package/ts3.5/dist/es6/search-form/lib/themes.d.ts +0 -21
  215. package/ts3.5/dist/es6/text-input/index.d.ts +0 -7
  216. package/ts3.5/dist/es6/text-input/lib/TextInput.d.ts +0 -21
  217. package/ts3.5/dist/es6/text-input/lib/TextInputField.d.ts +0 -8
  218. package/ts3.5/dist/es6/text-input/lib/TextInputHint.d.ts +0 -13
  219. package/ts3.5/dist/es6/text-input/lib/TextInputLabel.d.ts +0 -17
  220. package/ts3.5/dist/es6/text-input/lib/hooks/useTextInputField.d.ts +0 -19
  221. package/ts3.5/dist/es6/text-input/lib/hooks/useTextInputHint.d.ts +0 -15
  222. package/ts3.5/dist/es6/text-input/lib/hooks/useTextInputLabel.d.ts +0 -15
  223. package/ts3.5/dist/es6/text-input/lib/hooks/useTextInputModel.d.ts +0 -17
@@ -37,9 +37,9 @@ import * as React from 'react';
37
37
  import { css } from '@emotion/core';
38
38
  import styled from '@emotion/styled';
39
39
  import { borderRadius, space, type } from '@workday/canvas-kit-react/tokens';
40
- import { DeprecatedDubLogoTitle, DeprecatedWorkdayLogoTitle } from './parts';
41
- import { deprecatedHeaderThemes } from './shared/themes';
42
- import { DeprecatedHeaderHeight, DeprecatedHeaderTheme, DeprecatedHeaderVariant, } from './shared/types';
40
+ import { DubLogoTitle, WorkdayLogoTitle } from './parts';
41
+ import { themes } from './shared/themes';
42
+ import { HeaderHeight, HeaderTheme, HeaderVariant } from './shared/types';
43
43
  import { Hyperlink, IconButton } from '@workday/canvas-kit-react/button';
44
44
  import { SystemIcon } from '@workday/canvas-kit-react/icon';
45
45
  import { justifyIcon } from '@workday/canvas-system-icons-web';
@@ -48,9 +48,7 @@ var HeaderShell = styled('div')(__assign(__assign({ display: 'flex', alignItems:
48
48
  var variant = _a.variant, themeColor = _a.themeColor;
49
49
  return (__assign(__assign({
50
50
  // Only the variant Full has a large header, all the other one (Dub, Global) have a small header height
51
- height: variant === DeprecatedHeaderVariant.Full
52
- ? DeprecatedHeaderHeight.Large
53
- : DeprecatedHeaderHeight.Small, background: deprecatedHeaderThemes[themeColor].background }, deprecatedHeaderThemes[themeColor].depth), { color: deprecatedHeaderThemes[themeColor].color }));
51
+ height: variant === HeaderVariant.Full ? HeaderHeight.Large : HeaderHeight.Small, background: themes[themeColor].background }, themes[themeColor].depth), { color: themes[themeColor].color }));
54
52
  });
55
53
  var BrandSlot = styled('div')({
56
54
  height: '100%',
@@ -67,7 +65,7 @@ var BrandLink = styled(Hyperlink)({
67
65
  });
68
66
  var navStyle = function (_a) {
69
67
  var themeColor = _a.themeColor;
70
- var theme = deprecatedHeaderThemes[themeColor];
68
+ var theme = themes[themeColor];
71
69
  return css({
72
70
  nav: {
73
71
  display: 'flex',
@@ -175,17 +173,17 @@ var Brand = /** @class */ (function (_super) {
175
173
  return _super !== null && _super.apply(this, arguments) || this;
176
174
  }
177
175
  Brand.prototype.render = function () {
178
- var _a = this.props, _b = _a.variant, variant = _b === void 0 ? DeprecatedHeaderVariant.Dub : _b, brand = _a.brand, _c = _a.themeColor, themeColor = _c === void 0 ? DeprecatedHeaderTheme.White : _c, title = _a.title;
176
+ var _a = this.props, _b = _a.variant, variant = _b === void 0 ? HeaderVariant.Dub : _b, brand = _a.brand, _c = _a.themeColor, themeColor = _c === void 0 ? HeaderTheme.White : _c, title = _a.title;
179
177
  switch (variant) {
180
- case DeprecatedHeaderVariant.Global: {
178
+ case HeaderVariant.Global: {
181
179
  return React.createElement("span", null, brand);
182
180
  }
183
- case DeprecatedHeaderVariant.Full: {
184
- return (React.createElement("span", null, brand || (React.createElement(DeprecatedWorkdayLogoTitle, { title: title ? title : '', themeColor: themeColor }))));
181
+ case HeaderVariant.Full: {
182
+ return (React.createElement("span", null, brand || React.createElement(WorkdayLogoTitle, { title: title ? title : '', themeColor: themeColor })));
185
183
  }
186
- // DeprecatedHeaderVariant.Dub is default
184
+ // HeaderVariant.Dub is default
187
185
  default: {
188
- return (React.createElement("span", null, brand || React.createElement(DeprecatedDubLogoTitle, { title: title ? title : '', themeColor: themeColor })));
186
+ return (React.createElement("span", null, brand || React.createElement(DubLogoTitle, { title: title ? title : '', themeColor: themeColor })));
189
187
  }
190
188
  }
191
189
  };
@@ -197,7 +195,7 @@ var MenuIconButton = /** @class */ (function (_super) {
197
195
  return _super !== null && _super.apply(this, arguments) || this;
198
196
  }
199
197
  MenuIconButton.prototype.render = function () {
200
- var _a = this.props, _b = _a.themeColor, themeColor = _b === void 0 ? DeprecatedHeaderTheme.White : _b, menuToggle = _a.menuToggle, onMenuClick = _a.onMenuClick;
198
+ var _a = this.props, _b = _a.themeColor, themeColor = _b === void 0 ? HeaderTheme.White : _b, menuToggle = _a.menuToggle, onMenuClick = _a.onMenuClick;
201
199
  if (menuToggle) {
202
200
  var menuToggleElement = menuToggle;
203
201
  var onClick = menuToggleElement.props.onClick
@@ -208,26 +206,15 @@ var MenuIconButton = /** @class */ (function (_super) {
208
206
  className: 'canvas-header--menu-icon',
209
207
  });
210
208
  }
211
- return (React.createElement(IconButton, { variant: themeColor === DeprecatedHeaderTheme.White ? 'circle' : 'inverse', icon: justifyIcon, className: 'canvas-header--menu-icon', "aria-label": "Open Menu", onClick: onMenuClick }));
209
+ return (React.createElement(IconButton, { variant: themeColor === HeaderTheme.White ? 'circle' : 'inverse', icon: justifyIcon, className: 'canvas-header--menu-icon', "aria-label": "Open Menu", onClick: onMenuClick }));
212
210
  };
213
211
  return MenuIconButton;
214
212
  }(React.Component));
215
- /**
216
- * ### Deprecated Header
217
- *
218
- * As of Canvas Kit v6, this component is being soft-deprecated.
219
- * It will be hard-deprecated (completely removed) in v7. Please see the
220
- * [migration guide](https://workday.github.io/canvas-kit/?path=/story/welcome-migration-guides-v6-0--page)
221
- * for more information.
222
- */
223
213
  var Header = /** @class */ (function (_super) {
224
214
  __extends(Header, _super);
225
215
  function Header() {
226
216
  return _super !== null && _super.apply(this, arguments) || this;
227
217
  }
228
- Header.prototype.componentDidMount = function () {
229
- console.warn("Header is being deprecated and will be removed in Canvas Kit V7.\n\n For more information, please see the V6 migration guide:\n\n https://workday.github.io/canvas-kit/?path=/story/welcome-migration-guides-v6-0--page\n ");
230
- };
231
218
  /**
232
219
  * Helper that recursively maps ReactNodes to their theme-based equivalent.
233
220
  * Any children that are included in a Header may need to undergo transformation
@@ -248,7 +235,7 @@ var Header = /** @class */ (function (_super) {
248
235
  }
249
236
  var propsChildren = child.props.children;
250
237
  var singleChild = React.Children.count(propsChildren) === 1 && propsChildren;
251
- var iconButtonVariant = _this.props.themeColor === DeprecatedHeaderTheme.White ? 'circle' : 'inverse';
238
+ var iconButtonVariant = _this.props.themeColor === HeaderTheme.White ? 'circle' : 'inverse';
252
239
  // Convert old method of SystemIcon into IconButton. If SystemIcon is within a link, make sure it's passed through
253
240
  if (child.type === 'a' && singleChild && singleChild.type === SystemIcon) {
254
241
  var href_1 = child.props.href;
@@ -284,7 +271,7 @@ var Header = /** @class */ (function (_super) {
284
271
  });
285
272
  };
286
273
  Header.prototype.render = function () {
287
- var _a = this.props, menuToggle = _a.menuToggle, _b = _a.themeColor, themeColor = _b === void 0 ? DeprecatedHeaderTheme.White : _b, _c = _a.variant, variant = _c === void 0 ? DeprecatedHeaderVariant.Dub : _c, centeredNav = _a.centeredNav, title = _a.title, brand = _a.brand, brandUrl = _a.brandUrl, onMenuClick = _a.onMenuClick, leftSlot = _a.leftSlot, isCollapsed = _a.isCollapsed, children = _a.children, elemProps = __rest(_a, ["menuToggle", "themeColor", "variant", "centeredNav", "title", "brand", "brandUrl", "onMenuClick", "leftSlot", "isCollapsed", "children"]);
274
+ var _a = this.props, menuToggle = _a.menuToggle, _b = _a.themeColor, themeColor = _b === void 0 ? HeaderTheme.White : _b, _c = _a.variant, variant = _c === void 0 ? HeaderVariant.Dub : _c, centeredNav = _a.centeredNav, title = _a.title, brand = _a.brand, brandUrl = _a.brandUrl, onMenuClick = _a.onMenuClick, leftSlot = _a.leftSlot, isCollapsed = _a.isCollapsed, children = _a.children, elemProps = __rest(_a, ["menuToggle", "themeColor", "variant", "centeredNav", "title", "brand", "brandUrl", "onMenuClick", "leftSlot", "isCollapsed", "children"]);
288
275
  /* Push everything to the right if:
289
276
  - on tablet and mobile screens
290
277
  - Search isn't enabled and the nav shouldn't be centered
@@ -302,8 +289,8 @@ var Header = /** @class */ (function (_super) {
302
289
  // TODO: This needs to get changed to IconButton when we get it restyled for headers
303
290
  React.createElement(MenuIconButton, { themeColor: themeColor, menuToggle: menuToggle, onMenuClick: onMenuClick })) : (this.renderChildren(children)))));
304
291
  };
305
- Header.Theme = DeprecatedHeaderTheme;
306
- Header.Variant = DeprecatedHeaderVariant;
292
+ Header.Theme = HeaderTheme;
293
+ Header.Variant = HeaderVariant;
307
294
  return Header;
308
295
  }(React.Component));
309
296
  export default Header;
@@ -1,11 +1,11 @@
1
1
  import * as React from 'react';
2
- import { DeprecatedHeaderTheme } from '../shared/types';
2
+ import { HeaderTheme } from '../shared/types';
3
3
  export declare type DubTitleProps = {
4
4
  /**
5
5
  * The theme of the DubLogoTitle. Accepts `White`, `Blue`, or `Transparent`.
6
- * @default DeprecatedHeaderTheme.White
6
+ * @default HeaderTheme.White
7
7
  */
8
- themeColor?: DeprecatedHeaderTheme;
8
+ themeColor?: HeaderTheme;
9
9
  /**
10
10
  * The text of the DubLogoTitle. Not used if `brand` is provided.
11
11
  */
@@ -15,16 +15,7 @@ export declare type DubTitleProps = {
15
15
  */
16
16
  bgColor?: string;
17
17
  };
18
- /**
19
- * ### Deprecated Dub Logo Title
20
- *
21
- * As of Canvas Kit v6, this component is being soft-deprecated.
22
- * It will be hard-deprecated (completely removed) in v7. Please see the
23
- * [migration guide](https://workday.github.io/canvas-kit/?path=/story/welcome-migration-guides-v6-0--page)
24
- * for more information.
25
- */
26
- export declare class DeprecatedDubLogoTitle extends React.Component<DubTitleProps> {
27
- componentDidMount(): void;
18
+ export declare class DubLogoTitle extends React.Component<DubTitleProps> {
28
19
  render(): JSX.Element;
29
20
  }
30
21
  //# sourceMappingURL=DubLogoTitle.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"DubLogoTitle.d.ts","sourceRoot":"","sources":["../../../../../header/lib/parts/DubLogoTitle.tsx"],"names":[],"mappings":"AAAA,OAAO,KAAK,KAAK,MAAM,OAAO,CAAC;AAG/B,OAAO,EAAyB,qBAAqB,EAAC,MAAM,iBAAiB,CAAC;AAI9E,oBAAY,aAAa,GAAG;IAC1B;;;OAGG;IACH,UAAU,CAAC,EAAE,qBAAqB,CAAC;IACnC;;OAEG;IACH,KAAK,CAAC,EAAE,MAAM,CAAC;IACf;;OAEG;IACH,OAAO,CAAC,EAAE,MAAM,CAAC;CAClB,CAAC;AA4CF;;;;;;;GAOG;AACH,qBAAa,sBAAuB,SAAQ,KAAK,CAAC,SAAS,CAAC,aAAa,CAAC;IACxE,iBAAiB;IAQjB,MAAM;CAgBP"}
1
+ {"version":3,"file":"DubLogoTitle.d.ts","sourceRoot":"","sources":["../../../../../header/lib/parts/DubLogoTitle.tsx"],"names":[],"mappings":"AAAA,OAAO,KAAK,KAAK,MAAM,OAAO,CAAC;AAG/B,OAAO,EAAe,WAAW,EAAC,MAAM,iBAAiB,CAAC;AAI1D,oBAAY,aAAa,GAAG;IAC1B;;;OAGG;IACH,UAAU,CAAC,EAAE,WAAW,CAAC;IACzB;;OAEG;IACH,KAAK,CAAC,EAAE,MAAM,CAAC;IACf;;OAEG;IACH,OAAO,CAAC,EAAE,MAAM,CAAC;CAClB,CAAC;AA2CF,qBAAa,YAAa,SAAQ,KAAK,CAAC,SAAS,CAAC,aAAa,CAAC;IAC9D,MAAM;CAgBP"}
@@ -25,7 +25,7 @@ var __assign = (this && this.__assign) || function () {
25
25
  import * as React from 'react';
26
26
  import styled from '@emotion/styled';
27
27
  import { colors, space } from '@workday/canvas-kit-react/tokens';
28
- import { DeprecatedHeaderHeight, DeprecatedHeaderTheme } from '../shared/types';
28
+ import { HeaderHeight, HeaderTheme } from '../shared/types';
29
29
  import chroma from 'chroma-js';
30
30
  import { dubLogoWhite, dubLogoBlue } from '@workday/canvas-kit-react/common';
31
31
  var LockupContainer = styled('div')({
@@ -34,7 +34,7 @@ var LockupContainer = styled('div')({
34
34
  var Lockup = styled('div')({
35
35
  display: 'flex',
36
36
  alignItems: 'center',
37
- height: DeprecatedHeaderHeight.Small,
37
+ height: HeaderHeight.Small,
38
38
  paddingLeft: space.m,
39
39
  }, function (_a) {
40
40
  var bgColor = _a.bgColor;
@@ -52,8 +52,8 @@ var Title = styled('h3')({
52
52
  }, function (_a) {
53
53
  var themeColor = _a.themeColor;
54
54
  return ({
55
- color: themeColor === DeprecatedHeaderTheme.White ? colors.blueberry500 : colors.frenchVanilla100,
56
- borderLeft: "1px solid " + (themeColor === DeprecatedHeaderTheme.White
55
+ color: themeColor === HeaderTheme.White ? colors.blueberry500 : colors.frenchVanilla100,
56
+ borderLeft: "1px solid " + (themeColor === HeaderTheme.White
57
57
  ? colors.soap400
58
58
  : chroma(colors.frenchVanilla100)
59
59
  .alpha(0.3)
@@ -63,31 +63,20 @@ var Title = styled('h3')({
63
63
  var DubLogo = styled('div')({
64
64
  lineHeight: 0,
65
65
  });
66
- /**
67
- * ### Deprecated Dub Logo Title
68
- *
69
- * As of Canvas Kit v6, this component is being soft-deprecated.
70
- * It will be hard-deprecated (completely removed) in v7. Please see the
71
- * [migration guide](https://workday.github.io/canvas-kit/?path=/story/welcome-migration-guides-v6-0--page)
72
- * for more information.
73
- */
74
- var DeprecatedDubLogoTitle = /** @class */ (function (_super) {
75
- __extends(DeprecatedDubLogoTitle, _super);
76
- function DeprecatedDubLogoTitle() {
66
+ var DubLogoTitle = /** @class */ (function (_super) {
67
+ __extends(DubLogoTitle, _super);
68
+ function DubLogoTitle() {
77
69
  return _super !== null && _super.apply(this, arguments) || this;
78
70
  }
79
- DeprecatedDubLogoTitle.prototype.componentDidMount = function () {
80
- console.warn("DubLogoTitle is being deprecated and will be removed in Canvas Kit V7.\n\n For more information, please see the V6 migration guide:\n\n https://workday.github.io/canvas-kit/?path=/story/welcome-migration-guides-v6-0--page\n ");
81
- };
82
- DeprecatedDubLogoTitle.prototype.render = function () {
83
- var _a = this.props, _b = _a.themeColor, themeColor = _b === void 0 ? DeprecatedHeaderTheme.White : _b, title = _a.title;
71
+ DubLogoTitle.prototype.render = function () {
72
+ var _a = this.props, _b = _a.themeColor, themeColor = _b === void 0 ? HeaderTheme.White : _b, title = _a.title;
84
73
  return (React.createElement(LockupContainer, null,
85
74
  React.createElement(Lockup, __assign({}, this.props),
86
75
  React.createElement(DubLogo, __assign({}, this.props, { dangerouslySetInnerHTML: {
87
- __html: themeColor === DeprecatedHeaderTheme.White ? dubLogoBlue : dubLogoWhite,
76
+ __html: themeColor === HeaderTheme.White ? dubLogoBlue : dubLogoWhite,
88
77
  } })),
89
78
  title && React.createElement(Title, __assign({}, this.props), title))));
90
79
  };
91
- return DeprecatedDubLogoTitle;
80
+ return DubLogoTitle;
92
81
  }(React.Component));
93
- export { DeprecatedDubLogoTitle };
82
+ export { DubLogoTitle };
@@ -1,23 +1,24 @@
1
1
  import * as React from 'react';
2
2
  import { GrowthBehavior } from '@workday/canvas-kit-react/common';
3
3
  import { MenuItemProps } from '@workday/canvas-kit-preview-react/menu';
4
- import { SearchThemeAttributes, SearchTheme } from './themes';
5
- export interface SearchFormProps extends GrowthBehavior, React.FormHTMLAttributes<HTMLFormElement> {
4
+ import { SearchThemeAttributes } from '../shared/themes';
5
+ import { SearchTheme } from '../shared/types';
6
+ export interface SearchBarProps extends GrowthBehavior, React.FormHTMLAttributes<HTMLFormElement> {
6
7
  /**
7
- * The function called when the SearchForm form is submitted. The current input value is passed to the callback function.
8
+ * The function called when the SearchBar form is submitted. The current input value is passed to the callback function.
8
9
  */
9
10
  onSubmit: React.FormEventHandler<HTMLFormElement>;
10
11
  /**
11
- * If true, collapse the SearchForm text input into a toggle icon. Useful for responsive layouts.
12
+ * If true, collapse the SearchBar text input into a toggle icon. Useful for responsive layouts.
12
13
  * @default false
13
14
  */
14
15
  isCollapsed?: boolean;
15
16
  /**
16
- * The function called when the SearchForm text input changes.
17
+ * The function called when the SearchBar text input changes.
17
18
  */
18
19
  onInputChange?: React.ChangeEventHandler<HTMLInputElement>;
19
20
  /**
20
- * The autocomplete items of the SearchForm. This array of menu items is shown under the search bar.
21
+ * The autocomplete items of the SearchBar. This array of menu items is shown under the search bar.
21
22
  */
22
23
  autocompleteItems?: React.ReactElement<MenuItemProps>[];
23
24
  /**
@@ -25,73 +26,73 @@ export interface SearchFormProps extends GrowthBehavior, React.FormHTMLAttribute
25
26
  */
26
27
  searchTheme?: SearchTheme | SearchThemeAttributes;
27
28
  /**
28
- * The placeholder text of the SearchForm text input.
29
+ * The placeholder text of the SearchBar text input.
29
30
  * @default Search
30
31
  */
31
32
  placeholder?: string;
32
33
  /**
33
- * The initial value of the SearchForm text input.
34
+ * The initial value of the SearchBar text input.
34
35
  */
35
36
  initialValue?: string;
36
37
  /**
37
- * If true, right-align the SearchForm. If false, the text input should grow to left-align the SearchForm.
38
+ * If true, right-align the SearchBar. If false, the text input should grow to left-align the SearchBar.
38
39
  * @default false
39
40
  */
40
41
  rightAlign?: boolean;
41
42
  /**
42
- * The screenreader label text for the SearchForm text input.
43
+ * The screenreader label text for the SearchBar text input.
43
44
  * @default Search
44
45
  */
45
46
  inputLabel?: string;
46
47
  /**
47
- * The screenreader label text for the SearchForm submit button.
48
+ * The screenreader label text for the SearchBar submit button.
48
49
  * @default Search
49
50
  */
50
51
  submitAriaLabel?: string;
51
52
  /**
52
- * The screenreader label text for the SearchForm clear button.
53
+ * The screenreader label text for the SearchBar clear button.
53
54
  * @default Reset Search Form
54
55
  */
55
56
  clearButtonAriaLabel?: string;
56
57
  /**
57
- * The screenreader label text for the button to open the collapsed SearchForm.
58
+ * The screenreader label text for the button to open the collapsed SearchBar.
58
59
  * @default Open Search
59
60
  */
60
61
  openButtonAriaLabel?: string;
61
62
  /**
62
- * The screenreader label text for the button to close the open SearchForm.
63
+ * The screenreader label text for the button to close the open SearchBar.
63
64
  * @default Cancel
64
65
  */
65
66
  closeButtonAriaLabel?: string;
66
67
  /**
67
- * If true, render the SearchForm with a button to clear the text input.
68
+ * If true, render the SearchBar with a button to clear the text input.
68
69
  * @default true
69
70
  */
70
71
  showClearButton?: boolean;
71
72
  /**
72
- * Height of the Search Form in pixels
73
- * @default 40
73
+ * Height of the Search Bar in pixels
74
+ * @default: 40
74
75
  */
75
76
  height?: number;
76
77
  }
77
- export interface SearchFormState {
78
+ export interface SearchBarState {
78
79
  showForm: boolean;
79
80
  searchQuery: string;
80
81
  isFocused: boolean;
81
82
  }
82
- export declare class SearchForm extends React.Component<SearchFormProps, SearchFormState> {
83
+ export declare class SearchBar extends React.Component<SearchBarProps, SearchBarState> {
83
84
  static Theme: typeof SearchTheme;
84
85
  private inputRef;
85
86
  private openRef;
86
87
  private labelId;
87
- state: Readonly<SearchFormState>;
88
+ state: Readonly<SearchBarState>;
88
89
  private getTheme;
89
90
  private getThemeColors;
90
91
  getIconButtonType: () => "circle" | "square" | "inverse" | "squareFilled" | "plain" | "circleFilled" | "inverseFilled" | undefined;
91
92
  handleSubmit: (event: React.FormEvent<HTMLFormElement>) => void;
92
93
  openCollapsedSearch: () => void;
93
94
  closeCollapsedSearch: () => void;
94
- componentDidUpdate(prevProps: SearchFormProps, prevState: SearchFormState): void;
95
+ componentDidUpdate(prevProps: SearchBarProps, prevState: SearchBarState): void;
95
96
  focusInput: () => void;
96
97
  focusOpen: () => void;
97
98
  handleFocus: () => void;
@@ -99,4 +100,4 @@ export declare class SearchForm extends React.Component<SearchFormProps, SearchF
99
100
  handleSearchInputChange: (event: React.ChangeEvent<HTMLInputElement>) => void;
100
101
  render(): JSX.Element;
101
102
  }
102
- //# sourceMappingURL=SearchForm.d.ts.map
103
+ //# sourceMappingURL=SearchBar.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"SearchBar.d.ts","sourceRoot":"","sources":["../../../../../header/lib/parts/SearchBar.tsx"],"names":[],"mappings":"AAAA,OAAO,KAAK,KAAK,MAAM,OAAO,CAAC;AAG/B,OAAO,EAAC,cAAc,EAAS,MAAM,kCAAkC,CAAC;AAMxE,OAAO,EAAC,aAAa,EAAC,MAAM,wCAAwC,CAAC;AACrE,OAAO,EAAC,qBAAqB,EAAe,MAAM,kBAAkB,CAAC;AACrE,OAAO,EAAC,WAAW,EAAC,MAAM,iBAAiB,CAAC;AAI5C,MAAM,WAAW,cAAe,SAAQ,cAAc,EAAE,KAAK,CAAC,kBAAkB,CAAC,eAAe,CAAC;IAC/F;;OAEG;IACH,QAAQ,EAAE,KAAK,CAAC,gBAAgB,CAAC,eAAe,CAAC,CAAC;IAClD;;;OAGG;IACH,WAAW,CAAC,EAAE,OAAO,CAAC;IACtB;;OAEG;IACH,aAAa,CAAC,EAAE,KAAK,CAAC,kBAAkB,CAAC,gBAAgB,CAAC,CAAC;IAC3D;;OAEG;IACH,iBAAiB,CAAC,EAAE,KAAK,CAAC,YAAY,CAAC,aAAa,CAAC,EAAE,CAAC;IACxD;;OAEG;IACH,WAAW,CAAC,EAAE,WAAW,GAAG,qBAAqB,CAAC;IAClD;;;OAGG;IACH,WAAW,CAAC,EAAE,MAAM,CAAC;IACrB;;OAEG;IACH,YAAY,CAAC,EAAE,MAAM,CAAC;IACtB;;;OAGG;IACH,UAAU,CAAC,EAAE,OAAO,CAAC;IACrB;;;OAGG;IACH,UAAU,CAAC,EAAE,MAAM,CAAC;IACpB;;;OAGG;IACH,eAAe,CAAC,EAAE,MAAM,CAAC;IACzB;;;OAGG;IACH,oBAAoB,CAAC,EAAE,MAAM,CAAC;IAC9B;;;OAGG;IACH,mBAAmB,CAAC,EAAE,MAAM,CAAC;IAC7B;;;OAGG;IACH,oBAAoB,CAAC,EAAE,MAAM,CAAC;IAC9B;;;OAGG;IACH,eAAe,CAAC,EAAE,OAAO,CAAC;IAC1B;;;OAGG;IACH,MAAM,CAAC,EAAE,MAAM,CAAC;CACjB;AAED,MAAM,WAAW,cAAc;IAC7B,QAAQ,EAAE,OAAO,CAAC;IAClB,WAAW,EAAE,MAAM,CAAC;IACpB,SAAS,EAAE,OAAO,CAAC;CACpB;AAuMD,qBAAa,SAAU,SAAQ,KAAK,CAAC,SAAS,CAAC,cAAc,EAAE,cAAc,CAAC;IAC5E,MAAM,CAAC,KAAK,qBAAe;IAE3B,OAAO,CAAC,QAAQ,CAAuC;IACvD,OAAO,CAAC,OAAO,CAAwC;IACvD,OAAO,CAAC,OAAO,CAAU;IAEzB,KAAK,EAAE,QAAQ,CAAC,cAAc,CAAC,CAI7B;IAEF,OAAO,CAAC,QAAQ,CAUd;IAEF,OAAO,CAAC,cAAc,CAMpB;IAEF,iBAAiB,kHAOf;IAEF,YAAY,oDAOV;IAEF,mBAAmB,aAIjB;IAEF,oBAAoB,aAIlB;IAEF,kBAAkB,CAAC,SAAS,EAAE,cAAc,EAAE,SAAS,EAAE,cAAc;IAWvE,UAAU,aAIR;IAEF,SAAS,aAIP;IAEF,WAAW,aAET;IAEF,UAAU,aAER;IAEF,uBAAuB,uDAMrB;IAEF,MAAM;CAkGP"}
@@ -41,7 +41,8 @@ import { searchIcon, xIcon } from '@workday/canvas-system-icons-web';
41
41
  import { FormField, FormFieldLabelPosition } from '@workday/canvas-kit-react/form-field';
42
42
  import { Combobox } from '@workday/canvas-kit-labs-react/combobox';
43
43
  import { TextInput } from '@workday/canvas-kit-react/text-input';
44
- import { searchThemes, SearchTheme } from './themes';
44
+ import { searchThemes } from '../shared/themes';
45
+ import { SearchTheme } from '../shared/types';
45
46
  import chroma from 'chroma-js';
46
47
  import uuid from 'uuid/v4';
47
48
  function getInputColors(theme, isFocused) {
@@ -58,7 +59,7 @@ function getInputColors(theme, isFocused) {
58
59
  var formCollapsedBackground = colors.frenchVanilla100;
59
60
  var maxWidth = 480;
60
61
  var minWidth = 120;
61
- var StyledSearchForm = styled('form')({
62
+ var SearchForm = styled('form')({
62
63
  position: 'relative',
63
64
  flex: "1 1 auto",
64
65
  display: 'flex',
@@ -185,9 +186,9 @@ var SearchInput = styled(TextInput)(function (_a) {
185
186
  },
186
187
  } }, collapseStyles);
187
188
  });
188
- var SearchForm = /** @class */ (function (_super) {
189
- __extends(SearchForm, _super);
190
- function SearchForm() {
189
+ var SearchBar = /** @class */ (function (_super) {
190
+ __extends(SearchBar, _super);
191
+ function SearchBar() {
191
192
  var _this = _super !== null && _super.apply(this, arguments) || this;
192
193
  _this.inputRef = React.createRef();
193
194
  _this.openRef = React.createRef();
@@ -268,7 +269,7 @@ var SearchForm = /** @class */ (function (_super) {
268
269
  };
269
270
  return _this;
270
271
  }
271
- SearchForm.prototype.componentDidUpdate = function (prevProps, prevState) {
272
+ SearchBar.prototype.componentDidUpdate = function (prevProps, prevState) {
272
273
  var showFormToggled = this.state.showForm !== prevState.showForm;
273
274
  if (showFormToggled) {
274
275
  if (this.state.showForm) {
@@ -279,9 +280,9 @@ var SearchForm = /** @class */ (function (_super) {
279
280
  }
280
281
  }
281
282
  };
282
- SearchForm.prototype.render = function () {
283
+ SearchBar.prototype.render = function () {
283
284
  var _a = this.props, _b = _a.clearButtonAriaLabel, clearButtonAriaLabel = _b === void 0 ? 'Reset Search Form' : _b, _c = _a.placeholder, placeholder = _c === void 0 ? 'Search' : _c, _d = _a.inputLabel, inputLabel = _d === void 0 ? 'Search' : _d, _e = _a.submitAriaLabel, submitAriaLabel = _e === void 0 ? 'Search' : _e, _f = _a.openButtonAriaLabel, openButtonAriaLabel = _f === void 0 ? 'Open Search' : _f, _g = _a.closeButtonAriaLabel, closeButtonAriaLabel = _g === void 0 ? 'Cancel' : _g, _h = _a.showClearButton, showClearButton = _h === void 0 ? true : _h, _j = _a.height, height = _j === void 0 ? 40 : _j, grow = _a.grow, onSubmit = _a.onSubmit, isCollapsed = _a.isCollapsed, onInputChange = _a.onInputChange, autocompleteItems = _a.autocompleteItems, initialValue = _a.initialValue, searchTheme = _a.searchTheme, rightAlign = _a.rightAlign, elemProps = __rest(_a, ["clearButtonAriaLabel", "placeholder", "inputLabel", "submitAriaLabel", "openButtonAriaLabel", "closeButtonAriaLabel", "showClearButton", "height", "grow", "onSubmit", "isCollapsed", "onInputChange", "autocompleteItems", "initialValue", "searchTheme", "rightAlign"]);
284
- return (React.createElement(StyledSearchForm, __assign({ role: "search", action: ".", rightAlign: rightAlign, grow: grow, "aria-labelledby": this.labelId, isCollapsed: isCollapsed, onSubmit: this.handleSubmit, showForm: this.state.showForm }, elemProps),
285
+ return (React.createElement(SearchForm, __assign({ role: "search", action: ".", rightAlign: rightAlign, grow: grow, "aria-labelledby": this.labelId, isCollapsed: isCollapsed, onSubmit: this.handleSubmit, showForm: this.state.showForm }, elemProps),
285
286
  React.createElement(SearchContainer, { height: height },
286
287
  React.createElement(SearchIcon, { "aria-label": submitAriaLabel, icon: searchIcon, isCollapsed: isCollapsed, variant: this.getIconButtonType(), type: "submit", isHidden: !!isCollapsed && !this.state.showForm }),
287
288
  React.createElement(SearchIcon, { "aria-label": openButtonAriaLabel, icon: searchIcon, isCollapsed: isCollapsed, variant: this.getIconButtonType(), onClick: this.openCollapsedSearch, ref: this.openRef, type: "button", isHidden: !isCollapsed || (!!isCollapsed && this.state.showForm) }),
@@ -290,7 +291,7 @@ var SearchForm = /** @class */ (function (_super) {
290
291
  React.createElement(SearchInput, { ref: this.inputRef, value: this.state.searchQuery, placeholder: placeholder, isCollapsed: isCollapsed, inputColors: this.getThemeColors(), height: height, name: "search" }))),
291
292
  React.createElement(CloseButton, { "aria-label": closeButtonAriaLabel, icon: xIcon, isCollapsed: isCollapsed, variant: "plain", showForm: this.state.showForm, onClick: this.closeCollapsedSearch, type: "button" }))));
292
293
  };
293
- SearchForm.Theme = SearchTheme;
294
- return SearchForm;
294
+ SearchBar.Theme = SearchTheme;
295
+ return SearchBar;
295
296
  }(React.Component));
296
- export { SearchForm };
297
+ export { SearchBar };
@@ -1,11 +1,11 @@
1
1
  import * as React from 'react';
2
- import { DeprecatedHeaderTheme, DeprecatedHeaderVariant } from '../shared/types';
2
+ import { HeaderTheme, HeaderVariant } from '../shared/types';
3
3
  export declare type WorkdayLogoTitleProps = {
4
4
  /**
5
5
  * The theme of the WorkdayLogoTitle. Accepts `White`, `Blue`, or `Transparent`.
6
- * @default DeprecatedHeaderTheme.White
6
+ * @default HeaderTheme.White
7
7
  */
8
- themeColor?: DeprecatedHeaderTheme;
8
+ themeColor?: HeaderTheme;
9
9
  /**
10
10
  * The text of the WorkdayLogoTitle. Not used if `brand` is provided.
11
11
  * @default ''
@@ -14,18 +14,9 @@ export declare type WorkdayLogoTitleProps = {
14
14
  /**
15
15
  * The variant of the WorkdayLogoTitle.
16
16
  */
17
- variant?: DeprecatedHeaderVariant;
17
+ variant?: HeaderVariant;
18
18
  };
19
- /**
20
- * ### Deprecated Workday Logo Title
21
- *
22
- * As of Canvas Kit v6, this component is being soft-deprecated.
23
- * It will be hard-deprecated (completely removed) in v7. Please see the
24
- * [migration guide](https://workday.github.io/canvas-kit/?path=/story/welcome-migration-guides-v6-0--page)
25
- * for more information.
26
- */
27
- export declare class DeprecatedWorkdayLogoTitle extends React.Component<WorkdayLogoTitleProps> {
28
- componentDidMount(): void;
19
+ export declare class WorkdayLogoTitle extends React.Component<WorkdayLogoTitleProps> {
29
20
  render(): JSX.Element;
30
21
  }
31
22
  //# sourceMappingURL=WorkdayLogoTitle.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"WorkdayLogoTitle.d.ts","sourceRoot":"","sources":["../../../../../header/lib/parts/WorkdayLogoTitle.tsx"],"names":[],"mappings":"AAAA,OAAO,KAAK,KAAK,MAAM,OAAO,CAAC;AAE/B,OAAO,EAEL,qBAAqB,EACrB,uBAAuB,EACxB,MAAM,iBAAiB,CAAC;AAKzB,oBAAY,qBAAqB,GAAG;IAClC;;;OAGG;IACH,UAAU,CAAC,EAAE,qBAAqB,CAAC;IACnC;;;OAGG;IACH,KAAK,CAAC,EAAE,MAAM,CAAC;IACf;;OAEG;IACH,OAAO,CAAC,EAAE,uBAAuB,CAAC;CACnC,CAAC;AAiDF;;;;;;;GAOG;AACH,qBAAa,0BAA2B,SAAQ,KAAK,CAAC,SAAS,CAAC,qBAAqB,CAAC;IACpF,iBAAiB;IAQV,MAAM;CA2Bd"}
1
+ {"version":3,"file":"WorkdayLogoTitle.d.ts","sourceRoot":"","sources":["../../../../../header/lib/parts/WorkdayLogoTitle.tsx"],"names":[],"mappings":"AAAA,OAAO,KAAK,KAAK,MAAM,OAAO,CAAC;AAE/B,OAAO,EAAe,WAAW,EAAE,aAAa,EAAC,MAAM,iBAAiB,CAAC;AAKzE,oBAAY,qBAAqB,GAAG;IAClC;;;OAGG;IACH,UAAU,CAAC,EAAE,WAAW,CAAC;IACzB;;;OAGG;IACH,KAAK,CAAC,EAAE,MAAM,CAAC;IACf;;OAEG;IACH,OAAO,CAAC,EAAE,aAAa,CAAC;CACzB,CAAC;AA6CF,qBAAa,gBAAiB,SAAQ,KAAK,CAAC,SAAS,CAAC,qBAAqB,CAAC;IACnE,MAAM;CAsBd"}
@@ -35,7 +35,7 @@ var __rest = (this && this.__rest) || function (s, e) {
35
35
  };
36
36
  import * as React from 'react';
37
37
  import styled from '@emotion/styled';
38
- import { DeprecatedHeaderHeight, DeprecatedHeaderTheme, DeprecatedHeaderVariant, } from '../shared/types';
38
+ import { HeaderHeight, HeaderTheme, HeaderVariant } from '../shared/types';
39
39
  import { miniWdayLogoBlue, wdayLogoWhite, wdayLogoBlue } from '@workday/canvas-kit-react/common';
40
40
  import { colors, space } from '@workday/canvas-kit-react/tokens';
41
41
  import chroma from 'chroma-js';
@@ -49,9 +49,7 @@ var Lockup = styled('div')({
49
49
  }, function (_a) {
50
50
  var variant = _a.variant;
51
51
  return ({
52
- height: variant === DeprecatedHeaderVariant.Global
53
- ? DeprecatedHeaderHeight.Small
54
- : DeprecatedHeaderHeight.Large,
52
+ height: variant === HeaderVariant.Global ? HeaderHeight.Small : HeaderHeight.Large,
55
53
  });
56
54
  });
57
55
  var Title = styled('h3')({
@@ -66,8 +64,8 @@ var Title = styled('h3')({
66
64
  }, function (_a) {
67
65
  var themeColor = _a.themeColor;
68
66
  return ({
69
- color: themeColor === DeprecatedHeaderTheme.White ? colors.blueberry500 : colors.frenchVanilla100,
70
- borderLeft: "1px solid " + (themeColor === DeprecatedHeaderTheme.White
67
+ color: themeColor === HeaderTheme.White ? colors.blueberry500 : colors.frenchVanilla100,
68
+ borderLeft: "1px solid " + (themeColor === HeaderTheme.White
71
69
  ? colors.soap400
72
70
  : chroma(colors.soap400)
73
71
  .alpha(0.4)
@@ -78,35 +76,24 @@ var WorkdayLogo = styled('span')({
78
76
  paddingLeft: space.m,
79
77
  lineHeight: 0,
80
78
  });
81
- /**
82
- * ### Deprecated Workday Logo Title
83
- *
84
- * As of Canvas Kit v6, this component is being soft-deprecated.
85
- * It will be hard-deprecated (completely removed) in v7. Please see the
86
- * [migration guide](https://workday.github.io/canvas-kit/?path=/story/welcome-migration-guides-v6-0--page)
87
- * for more information.
88
- */
89
- var DeprecatedWorkdayLogoTitle = /** @class */ (function (_super) {
90
- __extends(DeprecatedWorkdayLogoTitle, _super);
91
- function DeprecatedWorkdayLogoTitle() {
79
+ var WorkdayLogoTitle = /** @class */ (function (_super) {
80
+ __extends(WorkdayLogoTitle, _super);
81
+ function WorkdayLogoTitle() {
92
82
  return _super !== null && _super.apply(this, arguments) || this;
93
83
  }
94
- DeprecatedWorkdayLogoTitle.prototype.componentDidMount = function () {
95
- console.warn("WorkdayLogoTitle is being deprecated and will be removed in Canvas Kit V7.\n\n For more information, please see the V6 migration guide:\n\n https://workday.github.io/canvas-kit/?path=/story/welcome-migration-guides-v6-0--page\n ");
96
- };
97
- DeprecatedWorkdayLogoTitle.prototype.render = function () {
98
- var _a = this.props, _b = _a.themeColor, themeColor = _b === void 0 ? DeprecatedHeaderTheme.White : _b, _c = _a.title, title = _c === void 0 ? '' : _c, variant = _a.variant, elemProps = __rest(_a, ["themeColor", "title", "variant"]);
84
+ WorkdayLogoTitle.prototype.render = function () {
85
+ var _a = this.props, _b = _a.themeColor, themeColor = _b === void 0 ? HeaderTheme.White : _b, _c = _a.title, title = _c === void 0 ? '' : _c, variant = _a.variant, elemProps = __rest(_a, ["themeColor", "title", "variant"]);
99
86
  return (React.createElement(LockupContainer, null,
100
87
  React.createElement(Lockup, __assign({}, this.props, elemProps),
101
88
  React.createElement(WorkdayLogo, __assign({}, this.props, { dangerouslySetInnerHTML: {
102
- __html: themeColor === DeprecatedHeaderTheme.White
103
- ? variant === DeprecatedHeaderVariant.Global
89
+ __html: themeColor === HeaderTheme.White
90
+ ? variant === HeaderVariant.Global
104
91
  ? miniWdayLogoBlue
105
92
  : wdayLogoBlue
106
93
  : wdayLogoWhite,
107
94
  } })),
108
95
  title && React.createElement(Title, __assign({}, this.props), title))));
109
96
  };
110
- return DeprecatedWorkdayLogoTitle;
97
+ return WorkdayLogoTitle;
111
98
  }(React.Component));
112
- export { DeprecatedWorkdayLogoTitle };
99
+ export { WorkdayLogoTitle };
@@ -1,3 +1,4 @@
1
- export { DeprecatedDubLogoTitle } from './DubLogoTitle';
2
- export { DeprecatedWorkdayLogoTitle } from './WorkdayLogoTitle';
1
+ export { DubLogoTitle } from './DubLogoTitle';
2
+ export { SearchBar, SearchBarProps } from './SearchBar';
3
+ export { WorkdayLogoTitle } from './WorkdayLogoTitle';
3
4
  //# sourceMappingURL=index.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../../../header/lib/parts/index.ts"],"names":[],"mappings":"AAAA,OAAO,EAAC,sBAAsB,EAAC,MAAM,gBAAgB,CAAC;AACtD,OAAO,EAAC,0BAA0B,EAAC,MAAM,oBAAoB,CAAC"}
1
+ {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../../../header/lib/parts/index.ts"],"names":[],"mappings":"AAAA,OAAO,EAAC,YAAY,EAAC,MAAM,gBAAgB,CAAC;AAC5C,OAAO,EAAC,SAAS,EAAE,cAAc,EAAC,MAAM,aAAa,CAAC;AACtD,OAAO,EAAC,gBAAgB,EAAC,MAAM,oBAAoB,CAAC"}
@@ -1,2 +1,3 @@
1
- export { DeprecatedDubLogoTitle } from './DubLogoTitle';
2
- export { DeprecatedWorkdayLogoTitle } from './WorkdayLogoTitle';
1
+ export { DubLogoTitle } from './DubLogoTitle';
2
+ export { SearchBar } from './SearchBar';
3
+ export { WorkdayLogoTitle } from './WorkdayLogoTitle';
@@ -1,13 +1,5 @@
1
1
  import { CSSProperties } from '@workday/canvas-kit-react/tokens';
2
- /**
3
- * ### Deprecated Header Theme Attributes Interface
4
- *
5
- * As of Canvas Kit v6, this type interface is being soft-deprecated along with the rest of the labs/header package.
6
- * It will be hard-deprecated (completely removed) in v7. Please see the
7
- * [migration guide](https://workday.github.io/canvas-kit/?path=/story/welcome-migration-guides-v6-0--page)
8
- * for more information.
9
- */
10
- export interface DeprecatedHeaderThemeAttributes {
2
+ export interface ThemeAttributes {
11
3
  color: string;
12
4
  background: string;
13
5
  depth: CSSProperties;
@@ -20,24 +12,23 @@ export interface DeprecatedHeaderThemeAttributes {
20
12
  currentLinkColor: string;
21
13
  chipColor: string;
22
14
  }
23
- /**
24
- * ### Deprecated Header Themes Interface
25
- *
26
- * As of Canvas Kit v6, this type interface is being soft-deprecated along with the rest of the labs/header package.
27
- * It will be hard-deprecated (completely removed) in v7. Please see the
28
- * [migration guide](https://workday.github.io/canvas-kit/?path=/story/welcome-migration-guides-v6-0--page)
29
- * for more information.
30
- */
31
- export interface DeprecatedHeaderThemes {
32
- [key: string]: DeprecatedHeaderThemeAttributes;
15
+ export interface Themes {
16
+ [key: string]: ThemeAttributes;
33
17
  }
34
- /**
35
- * ### Deprecated Header Themes
36
- *
37
- * As of Canvas Kit v6, this theme object is being soft-deprecated along with the rest of the labs/header package.
38
- * It will be hard-deprecated (completely removed) in v7. Please see the
39
- * [migration guide](https://workday.github.io/canvas-kit/?path=/story/welcome-migration-guides-v6-0--page)
40
- * for more information.
41
- */
42
- export declare const deprecatedHeaderThemes: DeprecatedHeaderThemes;
18
+ export declare const themes: Themes;
19
+ export interface SearchThemeAttributes {
20
+ background?: string;
21
+ backgroundFocus?: string;
22
+ backgroundHover?: string;
23
+ color?: string;
24
+ colorFocus?: string;
25
+ placeholderColor?: string;
26
+ placeholderColorFocus?: string;
27
+ boxShadow?: string | string[];
28
+ boxShadowFocus?: string | string[];
29
+ }
30
+ export interface SearchThemes {
31
+ [key: string]: SearchThemeAttributes;
32
+ }
33
+ export declare const searchThemes: SearchThemes;
43
34
  //# sourceMappingURL=themes.d.ts.map