@steroidsjs/core 3.0.0-beta.1 → 3.0.0-beta.2

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (315) hide show
  1. package/components/ClientStorageComponent.js +1 -0
  2. package/components/HtmlComponent.js +3 -1
  3. package/components/LocaleComponent.js +6 -5
  4. package/components/ResourceComponent.js +2 -0
  5. package/components/StoreComponent.js +2 -0
  6. package/components/social/FacebookProvider.js +2 -0
  7. package/hooks/useAbsolutePositioning.js +7 -4
  8. package/hooks/useApplication.d.ts +0 -1
  9. package/hooks/useApplication.js +3 -1
  10. package/index.d.ts +1 -1
  11. package/package.json +11 -13
  12. package/reducers/fields.d.ts +9 -7
  13. package/reducers/fields.js +3 -2
  14. package/ui/content/Alert/demo/description.d.ts +0 -1
  15. package/ui/content/Alert/demo/icon.d.ts +0 -1
  16. package/ui/content/Alert/demo/text.d.ts +0 -1
  17. package/ui/content/Avatar/demo/custome size.d.ts +0 -1
  18. package/ui/content/Avatar/demo/group.d.ts +0 -1
  19. package/ui/content/Avatar/demo/shape.d.ts +0 -1
  20. package/ui/content/Avatar/demo/size.d.ts +0 -1
  21. package/ui/content/Avatar/demo/title.d.ts +0 -1
  22. package/ui/content/Calendar/Calendar.d.ts +1 -1
  23. package/ui/content/Calendar/demo/basic.d.ts +0 -1
  24. package/ui/content/Card/demo/basic.d.ts +0 -1
  25. package/ui/content/Card/demo/basic.js +1 -0
  26. package/ui/content/Card/demo/border color.d.ts +0 -1
  27. package/ui/content/Card/demo/border color.js +2 -1
  28. package/ui/content/Card/demo/color.d.ts +0 -1
  29. package/ui/content/Card/demo/color.js +2 -1
  30. package/ui/content/Card/demo/header.d.ts +0 -6
  31. package/ui/content/Card/demo/header.js +4 -3
  32. package/ui/content/Card/demo/hover.d.ts +0 -6
  33. package/ui/content/Card/demo/hover.js +3 -2
  34. package/ui/content/Card/demo/link.d.ts +0 -6
  35. package/ui/content/Card/demo/link.js +2 -1
  36. package/ui/content/Card/demo/orientation.d.ts +0 -1
  37. package/ui/content/Card/demo/orientation.js +2 -1
  38. package/ui/content/Collapse/demo/accordion.d.ts +0 -1
  39. package/ui/content/Collapse/demo/basic.d.ts +0 -1
  40. package/ui/content/Collapse/demo/borderless.d.ts +0 -1
  41. package/ui/content/Collapse/demo/disable.d.ts +0 -1
  42. package/ui/content/Collapse/demo/icon position.d.ts +0 -1
  43. package/ui/content/Collapse/demo/icon.d.ts +0 -1
  44. package/ui/content/Collapse/demo/icon.js +1 -0
  45. package/ui/content/Collapse/demo/onChange.d.ts +0 -1
  46. package/ui/content/Collapse/demo/show icon.d.ts +0 -1
  47. package/ui/content/Detail/demo/basic.d.ts +0 -1
  48. package/ui/content/Detail/demo/colors.d.ts +0 -1
  49. package/ui/content/Detail/demo/colors.js +2 -1
  50. package/ui/content/Detail/demo/controls.d.ts +0 -1
  51. package/ui/content/Detail/demo/layout.d.ts +0 -1
  52. package/ui/content/Detail/demo/responsive.d.ts +0 -1
  53. package/ui/content/Detail/demo/sizes.d.ts +0 -1
  54. package/ui/crud/Crud/CrudModal.d.ts +0 -1
  55. package/ui/crud/Crud/demo/default.d.ts +0 -1
  56. package/ui/form/AutoCompleteField/demo/basic.d.ts +0 -1
  57. package/ui/form/AutoCompleteField/demo/disabled.d.ts +0 -1
  58. package/ui/form/AutoCompleteField/demo/errors.d.ts +0 -1
  59. package/ui/form/AutoCompleteField/demo/placeholder.d.ts +0 -1
  60. package/ui/form/AutoCompleteField/demo/required.d.ts +0 -1
  61. package/ui/form/AutoCompleteField/demo/sizes.d.ts +0 -1
  62. package/ui/form/BlankField/demo/basic.d.ts +0 -1
  63. package/ui/form/Button/demo/badge.d.ts +0 -1
  64. package/ui/form/Button/demo/basic.d.ts +0 -1
  65. package/ui/form/Button/demo/block.d.ts +0 -1
  66. package/ui/form/Button/demo/colors.d.ts +0 -1
  67. package/ui/form/Button/demo/confirm.d.ts +0 -1
  68. package/ui/form/Button/demo/disabled.d.ts +0 -1
  69. package/ui/form/Button/demo/hint.d.ts +0 -1
  70. package/ui/form/Button/demo/icon.d.ts +0 -1
  71. package/ui/form/Button/demo/link.d.ts +0 -1
  72. package/ui/form/Button/demo/sizes.d.ts +0 -1
  73. package/ui/form/Button/demo/tags.d.ts +0 -1
  74. package/ui/form/CheckboxField/demo/basic.d.ts +0 -1
  75. package/ui/form/CheckboxField/demo/disabled.d.ts +0 -1
  76. package/ui/form/CheckboxField/demo/errors.d.ts +0 -1
  77. package/ui/form/CheckboxField/demo/required.d.ts +0 -1
  78. package/ui/form/CheckboxListField/demo/basic.d.ts +0 -1
  79. package/ui/form/CheckboxListField/demo/disabled.d.ts +0 -1
  80. package/ui/form/CheckboxListField/demo/errors.d.ts +0 -1
  81. package/ui/form/CheckboxListField/demo/required.d.ts +0 -1
  82. package/ui/form/DateField/demo/basic.d.ts +0 -1
  83. package/ui/form/DateField/demo/disabled.d.ts +0 -1
  84. package/ui/form/DateField/demo/errors.d.ts +0 -1
  85. package/ui/form/DateField/demo/icon.d.ts +0 -1
  86. package/ui/form/DateField/demo/placeholder.d.ts +0 -1
  87. package/ui/form/DateField/demo/required.d.ts +0 -1
  88. package/ui/form/DateField/demo/sizes.d.ts +0 -1
  89. package/ui/form/DateField/useDateInputState.js +4 -1
  90. package/ui/form/DateField/useDateRange.js +1 -0
  91. package/ui/form/DateField/useDateTime.js +2 -0
  92. package/ui/form/DateRangeField/demo/basic.d.ts +0 -1
  93. package/ui/form/DateRangeField/demo/disabled.d.ts +0 -1
  94. package/ui/form/DateRangeField/demo/errors.d.ts +0 -1
  95. package/ui/form/DateRangeField/demo/icon.d.ts +0 -1
  96. package/ui/form/DateRangeField/demo/placeholder.d.ts +0 -1
  97. package/ui/form/DateRangeField/demo/required.d.ts +0 -1
  98. package/ui/form/DateTimeField/demo/basic.d.ts +0 -1
  99. package/ui/form/DateTimeField/demo/disabled.d.ts +0 -1
  100. package/ui/form/DateTimeField/demo/errors.d.ts +0 -1
  101. package/ui/form/DateTimeField/demo/icon.d.ts +0 -1
  102. package/ui/form/DateTimeField/demo/placeholder.d.ts +0 -1
  103. package/ui/form/DateTimeField/demo/required.d.ts +0 -1
  104. package/ui/form/DateTimeField/demo/showRemove.d.ts +0 -1
  105. package/ui/form/DateTimeRangeField/demo/basic.d.ts +0 -1
  106. package/ui/form/DateTimeRangeField/demo/disabled.d.ts +0 -1
  107. package/ui/form/DateTimeRangeField/demo/errors.d.ts +0 -1
  108. package/ui/form/DateTimeRangeField/demo/icon.d.ts +0 -1
  109. package/ui/form/DateTimeRangeField/demo/placeholder.d.ts +0 -1
  110. package/ui/form/DateTimeRangeField/demo/required.d.ts +0 -1
  111. package/ui/form/DateTimeRangeField/demo/showRemove.d.ts +0 -1
  112. package/ui/form/DropDownField/demo/auto-complete.d.ts +0 -1
  113. package/ui/form/DropDownField/demo/basic.d.ts +0 -1
  114. package/ui/form/DropDownField/demo/disabled.d.ts +0 -1
  115. package/ui/form/DropDownField/demo/errors.d.ts +0 -1
  116. package/ui/form/DropDownField/demo/multiple.d.ts +0 -1
  117. package/ui/form/DropDownField/demo/no-border.d.ts +0 -1
  118. package/ui/form/DropDownField/demo/placeholder.d.ts +0 -1
  119. package/ui/form/DropDownField/demo/required.d.ts +0 -1
  120. package/ui/form/DropDownField/demo/show-reset.d.ts +0 -1
  121. package/ui/form/DropDownField/demo/size.d.ts +0 -1
  122. package/ui/form/Field/demo/basic.d.ts +0 -1
  123. package/ui/form/Field/demo/component.d.ts +0 -1
  124. package/ui/form/Field/demo/model.d.ts +0 -1
  125. package/ui/form/Field/fieldWrapper.d.ts +0 -1
  126. package/ui/form/FieldLayout/demo/errors.d.ts +0 -1
  127. package/ui/form/FieldLayout/demo/layouts.d.ts +0 -1
  128. package/ui/form/FieldLayout/demo/required.d.ts +0 -1
  129. package/ui/form/FieldList/demo/basic.d.ts +0 -1
  130. package/ui/form/FieldList/demo/disabled.d.ts +0 -1
  131. package/ui/form/FieldSet/demo/basic.d.ts +0 -1
  132. package/ui/form/FileField/demo/basic.d.ts +0 -1
  133. package/ui/form/Form/demo/basic.d.ts +0 -1
  134. package/ui/form/Form/demo/border.d.ts +0 -1
  135. package/ui/form/Form/demo/horizontal.d.ts +0 -1
  136. package/ui/form/Form/demo/inline.d.ts +0 -1
  137. package/ui/form/HtmlField/demo/basic.d.ts +0 -1
  138. package/ui/form/InputField/demo/addons.d.ts +0 -1
  139. package/ui/form/InputField/demo/basic.d.ts +0 -1
  140. package/ui/form/InputField/demo/disabled.d.ts +0 -1
  141. package/ui/form/InputField/demo/errors.d.ts +0 -1
  142. package/ui/form/InputField/demo/mask.d.ts +0 -1
  143. package/ui/form/InputField/demo/placeholder.d.ts +0 -1
  144. package/ui/form/InputField/demo/required.d.ts +0 -1
  145. package/ui/form/InputField/demo/sizes.d.ts +0 -1
  146. package/ui/form/InputField/demo/textAddons.d.ts +0 -1
  147. package/ui/form/InputField/demo/types.d.ts +0 -1
  148. package/ui/form/NavField/demo/basic.d.ts +0 -1
  149. package/ui/form/NavField/demo/disabled.d.ts +0 -1
  150. package/ui/form/NavField/demo/errors.d.ts +0 -1
  151. package/ui/form/NavField/demo/layouts.d.ts +0 -1
  152. package/ui/form/NavField/demo/required.d.ts +0 -1
  153. package/ui/form/NumberField/demo/basic.d.ts +0 -1
  154. package/ui/form/NumberField/demo/disabled.d.ts +0 -1
  155. package/ui/form/NumberField/demo/errors.d.ts +0 -1
  156. package/ui/form/NumberField/demo/placeholder.d.ts +0 -1
  157. package/ui/form/NumberField/demo/required.d.ts +0 -1
  158. package/ui/form/NumberField/demo/sizes.d.ts +0 -1
  159. package/ui/form/PasswordField/demo/basic.d.ts +0 -1
  160. package/ui/form/PasswordField/demo/disabled.d.ts +0 -1
  161. package/ui/form/PasswordField/demo/errors.d.ts +0 -1
  162. package/ui/form/PasswordField/demo/placeholder.d.ts +0 -1
  163. package/ui/form/PasswordField/demo/required.d.ts +0 -1
  164. package/ui/form/PasswordField/demo/security.d.ts +0 -1
  165. package/ui/form/PasswordField/demo/sizes.d.ts +0 -1
  166. package/ui/form/RadioListField/RadioListField.js +3 -2
  167. package/ui/form/RadioListField/demo/basic.d.ts +0 -1
  168. package/ui/form/RadioListField/demo/disabled.d.ts +0 -1
  169. package/ui/form/RadioListField/demo/errors.d.ts +0 -1
  170. package/ui/form/RadioListField/demo/required.d.ts +0 -1
  171. package/ui/form/RateField/demo/allow-clear.d.ts +0 -1
  172. package/ui/form/RateField/demo/basic.d.ts +0 -1
  173. package/ui/form/RateField/demo/default-value.d.ts +0 -1
  174. package/ui/form/RateField/demo/disabled.d.ts +0 -1
  175. package/ui/form/RateField/demo/errors.d.ts +0 -1
  176. package/ui/form/RateField/demo/items-count.d.ts +0 -1
  177. package/ui/form/RateField/demo/required.d.ts +0 -1
  178. package/ui/form/ReCaptchaField/demo/basic.d.ts +0 -1
  179. package/ui/form/SliderField/SliderField.d.ts +3 -3
  180. package/ui/form/SliderField/demo/basic.d.ts +0 -1
  181. package/ui/form/SliderField/demo/disabled.d.ts +0 -1
  182. package/ui/form/SliderField/demo/errors.d.ts +0 -1
  183. package/ui/form/SliderField/demo/marks.d.ts +0 -1
  184. package/ui/form/SliderField/demo/min-max.d.ts +0 -1
  185. package/ui/form/SliderField/demo/onAfterChange.d.ts +0 -1
  186. package/ui/form/SliderField/demo/onChange.d.ts +0 -1
  187. package/ui/form/SliderField/demo/range.d.ts +0 -1
  188. package/ui/form/SwitcherField/demo/basic.d.ts +0 -1
  189. package/ui/form/SwitcherField/demo/disabled.d.ts +0 -1
  190. package/ui/form/SwitcherField/demo/errors.d.ts +0 -1
  191. package/ui/form/SwitcherField/demo/required.d.ts +0 -1
  192. package/ui/form/TextField/demo/basic.d.ts +0 -1
  193. package/ui/form/TextField/demo/disabled.d.ts +0 -1
  194. package/ui/form/TextField/demo/errors.d.ts +0 -1
  195. package/ui/form/TextField/demo/placeholder.d.ts +0 -1
  196. package/ui/form/TextField/demo/required.d.ts +0 -1
  197. package/ui/form/TextField/demo/sizes.d.ts +0 -1
  198. package/ui/form/TextField/demo/submit.d.ts +0 -1
  199. package/ui/form/TimeField/demo/basic.d.ts +0 -1
  200. package/ui/form/TimeField/demo/disabled.d.ts +0 -1
  201. package/ui/form/TimeField/demo/errors.d.ts +0 -1
  202. package/ui/form/TimeField/demo/icon.d.ts +0 -1
  203. package/ui/form/TimeField/demo/noBorder.d.ts +0 -1
  204. package/ui/form/TimeField/demo/placeholder.d.ts +0 -1
  205. package/ui/form/TimeField/demo/required.d.ts +0 -1
  206. package/ui/form/TimeField/demo/showRemove.d.ts +0 -1
  207. package/ui/form/validate.d.ts +1 -4
  208. package/ui/form/validate.js +10 -8
  209. package/ui/format/DateFormatter/DateFormatter.d.ts +0 -1
  210. package/ui/format/DateFormatter/demo/basic.d.ts +0 -1
  211. package/ui/format/DateTimeFormatter/DateTimeFormatter.d.ts +0 -1
  212. package/ui/format/DateTimeFormatter/demo/basic.d.ts +0 -1
  213. package/ui/format/EnumFormatter/EnumFormatter.d.ts +0 -1
  214. package/ui/format/FileSize/FileSize.d.ts +0 -1
  215. package/ui/format/Format/Format.d.ts +0 -1
  216. package/ui/format/MoneyFormatter/MoneyFormatter.d.ts +0 -1
  217. package/ui/icon/Icon/demo/icon.d.ts +0 -1
  218. package/ui/layout/Header/Header.d.ts +0 -1
  219. package/ui/layout/Loader/Loader.d.ts +0 -1
  220. package/ui/layout/Notifications/demo/basic.d.ts +0 -1
  221. package/ui/layout/Notifications/demo/position.d.ts +0 -1
  222. package/ui/layout/Notifications/demo/timeOut.d.ts +0 -1
  223. package/ui/layout/Portal.d.ts +6 -1
  224. package/ui/layout/Portal.js +2 -1
  225. package/ui/layout/ProgressBar/demo/percent.d.ts +0 -1
  226. package/ui/layout/ProgressBar/demo/showLabel.d.ts +0 -1
  227. package/ui/layout/ProgressBar/demo/sizes.d.ts +0 -1
  228. package/ui/layout/ProgressBar/demo/status.d.ts +0 -1
  229. package/ui/layout/ProgressBar/demo/type.d.ts +0 -1
  230. package/ui/layout/ProgressBar/index.d.ts +1 -1
  231. package/ui/layout/Skeleton/demo/animations.d.ts +0 -1
  232. package/ui/layout/Skeleton/demo/width height.d.ts +0 -1
  233. package/ui/layout/Skeleton/index.d.ts +1 -1
  234. package/ui/layout/Tooltip/Tooltip.d.ts +1 -2
  235. package/ui/layout/Tooltip/TooltipPortalInner.d.ts +4 -4
  236. package/ui/layout/Tooltip/TooltipPortalInner.js +9 -38
  237. package/ui/layout/Tooltip/demo/basic.d.ts +0 -1
  238. package/ui/list/CheckboxColumn/CheckboxColumn.d.ts +0 -1
  239. package/ui/list/CheckboxColumn/demo/basic.d.ts +0 -1
  240. package/ui/list/CheckboxColumn/demo/basic.js +1 -1
  241. package/ui/list/ControlsColumn/ControlsColumn.d.ts +0 -1
  242. package/ui/list/ControlsColumn/demo/basic.d.ts +0 -1
  243. package/ui/list/Empty/demo/basic.d.ts +0 -1
  244. package/ui/list/Empty/demo/custom-text.d.ts +0 -1
  245. package/ui/list/Grid/demo/basic.d.ts +0 -1
  246. package/ui/list/Grid/demo/controls.d.ts +0 -1
  247. package/ui/list/Grid/demo/empty.d.ts +0 -1
  248. package/ui/list/Grid/demo/empty.js +1 -1
  249. package/ui/list/Grid/demo/formatter.d.ts +0 -1
  250. package/ui/list/Grid/demo/indexing.d.ts +0 -1
  251. package/ui/list/Grid/demo/inner-search-form.d.ts +0 -1
  252. package/ui/list/Grid/demo/load-more.d.ts +0 -1
  253. package/ui/list/Grid/demo/pagination.d.ts +0 -1
  254. package/ui/list/Grid/demo/search-form.d.ts +0 -1
  255. package/ui/list/Grid/demo/search-form.js +1 -1
  256. package/ui/list/Grid/demo/sort.d.ts +0 -1
  257. package/ui/list/Grid/demo/visible.d.ts +0 -1
  258. package/ui/list/List/List.d.ts +0 -1
  259. package/ui/list/List/demo/basic.d.ts +0 -1
  260. package/ui/list/List/demo/condition.d.ts +0 -1
  261. package/ui/list/List/demo/condition.js +1 -1
  262. package/ui/list/List/demo/empty.d.ts +0 -1
  263. package/ui/list/List/demo/layout.d.ts +0 -1
  264. package/ui/list/List/demo/load-more.d.ts +0 -1
  265. package/ui/list/List/demo/pagination.d.ts +0 -1
  266. package/ui/list/List/demo/search-form.d.ts +0 -1
  267. package/ui/list/List/demo/sort.d.ts +0 -1
  268. package/ui/list/List/demo/sort.js +1 -1
  269. package/ui/list/Pagination/Pagination.js +2 -2
  270. package/ui/list/Pagination/demo/basic.d.ts +0 -1
  271. package/ui/list/Pagination/demo/load-more.d.ts +0 -1
  272. package/ui/list/Pagination/demo/sizes.d.ts +0 -1
  273. package/ui/list/PaginationSize/demo/basic.d.ts +0 -1
  274. package/ui/list/PaginationSize/demo/size.d.ts +0 -1
  275. package/ui/list/SearchForm/demo/basic.d.ts +0 -1
  276. package/ui/list/Steps/Steps.d.ts +1 -1
  277. package/ui/list/Steps/Steps.js +14 -5
  278. package/ui/list/Steps/index.d.ts +1 -1
  279. package/ui/modal/Modal/Modal.d.ts +0 -1
  280. package/ui/modal/Modal/Modal.js +1 -0
  281. package/ui/modal/Modal/demo/basic.d.ts +0 -1
  282. package/ui/modal/Modal/demo/closeTimeout.d.ts +0 -1
  283. package/ui/modal/Modal/demo/closing.d.ts +0 -1
  284. package/ui/modal/Modal/demo/component.d.ts +0 -1
  285. package/ui/modal/Modal/demo/controls.d.ts +0 -1
  286. package/ui/modal/Modal/demo/size.d.ts +0 -1
  287. package/ui/modal/ModalPortal/ModalPortal.d.ts +0 -1
  288. package/ui/modal/TwoFactorModal/TwoFactorModal.d.ts +0 -1
  289. package/ui/nav/Breadcrumbs/Breadcrumbs.d.ts +0 -1
  290. package/ui/nav/Breadcrumbs/demo/basic.d.ts +0 -1
  291. package/ui/nav/Breadcrumbs/demo/items.d.ts +0 -1
  292. package/ui/nav/Breadcrumbs/demo/page-title.d.ts +0 -1
  293. package/ui/nav/Controls/Controls.d.ts +0 -1
  294. package/ui/nav/Controls/demo/basic.d.ts +0 -1
  295. package/ui/nav/Link/Link.d.ts +0 -1
  296. package/ui/nav/Link/demo/badge.d.ts +0 -1
  297. package/ui/nav/Link/demo/basic.d.ts +0 -1
  298. package/ui/nav/Link/demo/colors.d.ts +0 -1
  299. package/ui/nav/Link/demo/confirm.d.ts +0 -1
  300. package/ui/nav/Link/demo/disabled.d.ts +0 -1
  301. package/ui/nav/Link/demo/hint.d.ts +0 -1
  302. package/ui/nav/Link/demo/icon.d.ts +0 -1
  303. package/ui/nav/Link/demo/sizes.d.ts +0 -1
  304. package/ui/nav/Nav/Nav.d.ts +0 -1
  305. package/ui/nav/Nav/demo/basic.d.ts +0 -1
  306. package/ui/nav/Nav/demo/layout.d.ts +0 -1
  307. package/ui/nav/Router/ConnectedRouter.d.ts +1 -1
  308. package/ui/nav/Router/Router.js +3 -1
  309. package/ui/nav/Tree/demo/auto-open-levels.d.ts +0 -1
  310. package/ui/nav/Tree/demo/basic.d.ts +0 -1
  311. package/ui/nav/Tree/demo/level.d.ts +0 -1
  312. package/ui/nav/Tree/demo/routes.d.ts +0 -1
  313. package/ui/nav/Tree/demo/selected-item.d.ts +0 -1
  314. package/utils/text.d.ts +1 -1
  315. package/utils/text.js +1 -0
@@ -22,6 +22,7 @@ var __importDefault = (this && this.__importDefault) || function (mod) {
22
22
  return (mod && mod.__esModule) ? mod : { "default": mod };
23
23
  };
24
24
  exports.__esModule = true;
25
+ /* eslint-disable no-unused-expressions */
25
26
  var cookie = __importStar(require("js-cookie"));
26
27
  var moment_1 = __importDefault(require("moment"));
27
28
  /**
@@ -58,9 +58,11 @@ var HtmlComponent = /** @class */ (function () {
58
58
  }
59
59
  };
60
60
  HtmlComponent.prototype.closest = function (element, className) {
61
+ // eslint-disable-next-line no-cond-assign
61
62
  while ((element = element.parentElement)
63
+ // eslint-disable-next-line no-empty
62
64
  && !element.classList.contains(className)) {
63
- } // eslint-disable-line no-empty
65
+ }
64
66
  return element;
65
67
  };
66
68
  HtmlComponent.prototype._applyModifiers = function (entity, modifiers) {
@@ -43,6 +43,7 @@ var LocaleComponent = /** @class */ (function () {
43
43
  this.translations = {};
44
44
  // Publish to global
45
45
  if (process.env.IS_SSR) {
46
+ // eslint-disable-next-line @typescript-eslint/ban-ts-comment
46
47
  // @ts-ignore
47
48
  global.__ = this.translate.bind(this);
48
49
  }
@@ -81,7 +82,7 @@ var LocaleComponent = /** @class */ (function () {
81
82
  message = this.translations[message] || message;
82
83
  // Cut react components
83
84
  var components = {};
84
- Object.keys(params).map(function (key) {
85
+ Object.keys(params).forEach(function (key) {
85
86
  if (isObject_1["default"](params[key])) {
86
87
  components[key] = params[key];
87
88
  params[key] = "!!" + key + "!!";
@@ -101,7 +102,7 @@ var LocaleComponent = /** @class */ (function () {
101
102
  }
102
103
  // Index components
103
104
  var indexedComponents = [];
104
- Object.keys(components).map(function (key) {
105
+ Object.keys(components).forEach(function (key) {
105
106
  var index = message.indexOf("!!" + key + "!!");
106
107
  if (index !== -1) {
107
108
  indexedComponents.push({
@@ -123,19 +124,19 @@ var LocaleComponent = /** @class */ (function () {
123
124
  // Split text to array, paste components
124
125
  var result = [];
125
126
  var textParts = message.split('!!component!!');
126
- for (var i = 0, j = 0; i < textParts.length; i++) {
127
+ for (var i = 0, j = 0; i < textParts.length; i += 1) {
127
128
  var isComponentAdded = false;
128
129
  if (j === 0
129
130
  && j < indexedComponents.length
130
131
  && indexedComponents[j].index === 0) {
131
132
  result.push(React.createElement("span", { key: "element-" + j }, indexedComponents[j].component));
132
133
  isComponentAdded = true;
133
- j++;
134
+ j += 1;
134
135
  }
135
136
  result.push(React.createElement("span", { key: "text-" + i }, textParts[i]));
136
137
  if (!isComponentAdded && j < indexedComponents.length) {
137
138
  result.push(React.createElement("span", { key: "element" + j }, indexedComponents[j].component));
138
- j++;
139
+ j += 1;
139
140
  }
140
141
  }
141
142
  return React.createElement("span", null, result);
@@ -22,6 +22,7 @@ var __importDefault = (this && this.__importDefault) || function (mod) {
22
22
  return (mod && mod.__esModule) ? mod : { "default": mod };
23
23
  };
24
24
  exports.__esModule = true;
25
+ /* eslint-disable @typescript-eslint/ban-ts-comment */
25
26
  var queryString = __importStar(require("qs"));
26
27
  var isArray_1 = __importDefault(require("lodash-es/isArray"));
27
28
  /**
@@ -63,6 +64,7 @@ var ResourceComponent = /** @class */ (function () {
63
64
  if (window.ymaps) {
64
65
  return new Promise(function (resolve) {
65
66
  // @ts-ignore
67
+ // eslint-disable-next-line implicit-arrow-linebreak
66
68
  return window.ymaps.ready(function () { return resolve(window.ymaps); });
67
69
  });
68
70
  }
@@ -14,6 +14,7 @@ var __importDefault = (this && this.__importDefault) || function (mod) {
14
14
  return (mod && mod.__esModule) ? mod : { "default": mod };
15
15
  };
16
16
  exports.__esModule = true;
17
+ /* eslint-disable no-restricted-globals */
17
18
  var redux_1 = require("redux");
18
19
  var connected_react_router_1 = require("connected-react-router");
19
20
  var history_1 = require("history");
@@ -119,6 +120,7 @@ var StoreComponent = /** @class */ (function () {
119
120
  return action(function (p) { return _this._prepare(p, dispatch, getState); }, getState, this._components);
120
121
  }
121
122
  // Promise, detect errors on rejects
123
+ // eslint-disable-next-line max-len
122
124
  // Detect action through instanceof Promise is not working in production mode, then used single detection by type
123
125
  if (typeof action === 'object'
124
126
  && typeof action.then === 'function'
@@ -36,6 +36,7 @@ var __generator = (this && this.__generator) || function (thisArg, body) {
36
36
  }
37
37
  };
38
38
  exports.__esModule = true;
39
+ /* eslint-disable @typescript-eslint/ban-ts-comment */
39
40
  var FacebookProvider = /** @class */ (function () {
40
41
  function FacebookProvider(components, config) {
41
42
  this._components = components;
@@ -76,6 +77,7 @@ var FacebookProvider = /** @class */ (function () {
76
77
  });
77
78
  }
78
79
  else {
80
+ // eslint-disable-next-line prefer-promise-reject-errors
79
81
  reject('FB error: ' + response.status);
80
82
  }
81
83
  }, {
@@ -24,7 +24,8 @@ function useAbsolutePositioning(props) {
24
24
  case 'topRight':
25
25
  // Проверка - выходит ли tooltip за верхний край страницы?
26
26
  // Если да - меняем позицию на bottom
27
- if (useAutoPositioning && ((parentDimensions.top - window.scrollY) <= Math.round(componentSize.height + props.gap))) {
27
+ if (useAutoPositioning
28
+ && ((parentDimensions.top - window.scrollY) <= Math.round(componentSize.height + props.gap))) {
28
29
  newStyle.top = parentDimensions.top + parentDimensions.height;
29
30
  newPosition = newPosition.replace('top', 'bottom');
30
31
  }
@@ -37,8 +38,8 @@ function useAbsolutePositioning(props) {
37
38
  case 'bottomRight':
38
39
  // Проверка - выходит ли tooltip за нижний край страницы?
39
40
  // Если да - меняем позицию на top
40
- if (useAutoPositioning && ((window.innerHeight - (parentDimensions.top + parentDimensions.height - window.scrollY)))
41
- <= Math.round(componentSize.height + props.gap)) {
41
+ if (useAutoPositioning
42
+ && ((window.innerHeight - (parentDimensions.top + parentDimensions.height - window.scrollY))) <= Math.round(componentSize.height + props.gap)) {
42
43
  newStyle.top = parentDimensions.top - componentSize.height;
43
44
  newPosition = newPosition.replace('bottom', 'top');
44
45
  }
@@ -64,7 +65,8 @@ function useAbsolutePositioning(props) {
64
65
  case 'rightBottom':
65
66
  // Проверка - выходит ли tooltip за правый край страницы?
66
67
  // Если да - меняем позицию на left
67
- if (useAutoPositioning && (document.body.clientWidth - parentDimensions.right <= Math.round(componentSize.width + props.gap))) {
68
+ if (useAutoPositioning
69
+ && (document.body.clientWidth - parentDimensions.right <= Math.round(componentSize.width + props.gap))) {
68
70
  newStyle.left = parentDimensions.left - componentSize.width;
69
71
  newPosition = newPosition.replace('right', 'left');
70
72
  }
@@ -137,6 +139,7 @@ function useAbsolutePositioning(props) {
137
139
  }
138
140
  setStyle(newStyle);
139
141
  setPosition(newPosition);
142
+ // eslint-disable-next-line react-hooks/exhaustive-deps
140
143
  }, [props.gap]);
141
144
  var onShow = react_1.useCallback(function () {
142
145
  if (timerRef.current) {
@@ -1,4 +1,3 @@
1
- /// <reference types="react" />
2
1
  import ClientStorageComponent from '../components/ClientStorageComponent';
3
2
  import HtmlComponent from '../components/HtmlComponent';
4
3
  import StoreComponent from '../components/StoreComponent';
@@ -130,7 +130,9 @@ function useApplication(config) {
130
130
  if (!(useGlobal || process.env.IS_SSR)) {
131
131
  content = (React.createElement(ComponentsProvider_1["default"], { components: components }, content));
132
132
  }
133
- return (React.createElement(react_redux_1.Provider, { store: components.store.store }, content));
133
+ return (
134
+ // @ts-ignore
135
+ React.createElement(react_redux_1.Provider, { store: components.store.store }, content));
134
136
  }, [components, config, useGlobal]);
135
137
  return { renderApplication: renderApplication, components: components };
136
138
  }
package/index.d.ts CHANGED
@@ -88,7 +88,7 @@ declare type CustomStyle = React.CSSProperties;
88
88
  * Переопределение view React компонента для кастомизации отображения
89
89
  * @example MyCustomView
90
90
  */
91
- declare type CustomView = React.ReactNode;
91
+ declare type CustomView = React.ReactNode | React.FunctionComponent;
92
92
 
93
93
  /**
94
94
  * HTTP метод
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@steroidsjs/core",
3
- "version": "3.0.0-beta.1",
3
+ "version": "3.0.0-beta.2",
4
4
  "description": "",
5
5
  "author": "Vladimir Kozhin <hello@kozhindev.com>",
6
6
  "repository": {
@@ -20,6 +20,7 @@
20
20
  "scripts": {
21
21
  "docs": "typedoc --ignoreCompilerErrors --json typedoc.json .",
22
22
  "test": "jest",
23
+ "lint": "eslint --ext .js,.jsx,.ts,.tsx ./src ./tests",
23
24
  "build": "tsc && cp ./{package.json,LICENSE,README.md} dist/ && cp src/index.d.ts dist/",
24
25
  "watch": "tsc -p tsconfig-debug.json"
25
26
  },
@@ -30,7 +31,7 @@
30
31
  "dot-prop-immutable": "^2.1.0",
31
32
  "fileup-core": "^1.2.7",
32
33
  "history": "^4.10.1",
33
- "intl-messageformat": "^9.11.0",
34
+ "intl-messageformat": "^10.1.4",
34
35
  "js-cookie": "^2.2.1",
35
36
  "load-js": "^3.0.3",
36
37
  "lodash": "^4.17.21",
@@ -39,10 +40,10 @@
39
40
  "path-to-regexp": "^1.7.0",
40
41
  "qs": "^6.9.4",
41
42
  "query-string": "^6.14.0",
42
- "react": "^17.0.2",
43
+ "react": "^18.1.0",
43
44
  "react-click-outside": "^3.0.1",
44
- "react-day-picker": "^7.4.8",
45
- "react-dom": "^17.0.2",
45
+ "react-day-picker": "^8.2.1",
46
+ "react-dom": "^18.1.0",
46
47
  "react-grid-gallery": "^0.4.8",
47
48
  "react-helmet": "^6.1.0",
48
49
  "react-image-crop": "^9.0.2",
@@ -50,7 +51,7 @@
50
51
  "react-redux": "7.1.1",
51
52
  "react-router": "^5.2.0",
52
53
  "react-router-dom": "^5.2.0",
53
- "react-use": "^17.1.0",
54
+ "react-use": "^17.4.0",
54
55
  "redux": "^4.0.4",
55
56
  "redux-mock-store": "^1.5.4",
56
57
  "set-cookie-parser": "^2.4.8"
@@ -61,13 +62,15 @@
61
62
  "@babel/preset-env": "^7.13.15",
62
63
  "@babel/preset-react": "^7.13.13",
63
64
  "@babel/preset-typescript": "^7.13.0",
65
+ "@steroidsjs/eslint-config": "^2.1.2",
64
66
  "@types/enzyme": "^3.10.8",
65
67
  "@types/enzyme-adapter-react-16": "^1.0.6",
66
68
  "@types/jest": "^26.0.22",
67
- "@types/markdown-to-jsx": "^6.11.3",
69
+ "@types/markdown-to-jsx": "^7.0.1",
68
70
  "@types/reach__router": "^1.3.7",
69
- "@types/react": "=17.0.3",
71
+ "@types/react": "^18.0.20",
70
72
  "@types/react-color": "^3.0.4",
73
+ "@types/react-dom": "^18.0.6",
71
74
  "@types/react-syntax-highlighter": "^13.5.0",
72
75
  "@types/webpack-env": "^1.16.0",
73
76
  "@typescript-eslint/eslint-plugin": "^4.15.0",
@@ -75,11 +78,6 @@
75
78
  "@wojtekmaj/enzyme-adapter-react-17": "^0.4.1",
76
79
  "enzyme": "^3.11.0",
77
80
  "eslint": "^7.20.0",
78
- "eslint-config-airbnb": "18.2.1",
79
- "eslint-plugin-import": "^2.22.1",
80
- "eslint-plugin-jsx-a11y": "^6.4.1",
81
- "eslint-plugin-react": "^7.21.5",
82
- "eslint-plugin-react-hooks": "^1.7.0",
83
81
  "jest": "^26.6.3",
84
82
  "jest-enzyme": "^7.1.2",
85
83
  "ts-jest": "^26.5.1",
@@ -1,11 +1,13 @@
1
- declare const _default: (state: {
2
- props: {};
3
- dataProvider: {};
4
- meta: any;
5
- }, action: any) => {
6
- props: {};
7
- dataProvider: {};
1
+ export interface IFieldsState {
2
+ props: Record<string, any>;
3
+ dataProvider: Record<string, any>;
4
+ meta: Record<string, any> | null;
5
+ }
6
+ export declare const normalizeName: (name: any) => any;
7
+ declare const _default: (state: IFieldsState, action: any) => {
8
8
  meta: any;
9
+ props: Record<string, any>;
10
+ dataProvider: Record<string, any>;
9
11
  };
10
12
  export default _default;
11
13
  export declare const isMetaFetched: (state: any) => boolean;
@@ -14,7 +14,7 @@ var __importDefault = (this && this.__importDefault) || function (mod) {
14
14
  return (mod && mod.__esModule) ? mod : { "default": mod };
15
15
  };
16
16
  exports.__esModule = true;
17
- exports.getDataProviderItems = exports.getModel = exports.getEnumLabels = exports.isMetaFetched = void 0;
17
+ exports.getDataProviderItems = exports.getModel = exports.getEnumLabels = exports.isMetaFetched = exports.normalizeName = void 0;
18
18
  var isString_1 = __importDefault(require("lodash-es/isString"));
19
19
  var get_1 = __importDefault(require("lodash-es/get"));
20
20
  var fields_1 = require("../actions/fields");
@@ -24,6 +24,7 @@ var initialState = {
24
24
  meta: null
25
25
  };
26
26
  var normalizeName = function (name) { return name.replace(/\\/g, '.').replace(/^\./, ''); };
27
+ exports.normalizeName = normalizeName;
27
28
  exports["default"] = (function (state, action) {
28
29
  var _a;
29
30
  if (state === void 0) { state = initialState; }
@@ -46,7 +47,7 @@ exports.getEnumLabels = getEnumLabels;
46
47
  var warnings = {};
47
48
  var getModel = function (state, name) {
48
49
  if (isString_1["default"](name)) {
49
- name = normalizeName(name);
50
+ name = exports.normalizeName(name);
50
51
  var meta = get_1["default"](state, ['fields', 'meta', name]) || null;
51
52
  if (!meta && exports.isMetaFetched(state) && !warnings[name]) {
52
53
  warnings[name] = true;
@@ -1,4 +1,3 @@
1
- /// <reference types="react" />
2
1
  declare const _default: () => JSX.Element;
3
2
  /**
4
3
  * Header+text with icon
@@ -1,4 +1,3 @@
1
- /// <reference types="react" />
2
1
  declare const _default: () => JSX.Element;
3
2
  /**
4
3
  * Header with icon and without icon
@@ -1,4 +1,3 @@
1
- /// <reference types="react" />
2
1
  declare const _default: () => JSX.Element;
3
2
  /**
4
3
  * Text with icon and without icon
@@ -1,4 +1,3 @@
1
- /// <reference types="react" />
2
1
  declare const _default: () => JSX.Element;
3
2
  /**
4
3
  * Custom size in numbers
@@ -1,4 +1,3 @@
1
- /// <reference types="react" />
2
1
  declare const _default: () => JSX.Element;
3
2
  /**
4
3
  * Group of avatars
@@ -1,4 +1,3 @@
1
- /// <reference types="react" />
2
1
  declare const _default: () => JSX.Element;
3
2
  /**
4
3
  * Basic sizes with image source, online status and square shape
@@ -1,4 +1,3 @@
1
- /// <reference types="react" />
2
1
  declare const _default: () => JSX.Element;
3
2
  /**
4
3
  * Basic sizes with image source and online status
@@ -1,4 +1,3 @@
1
- /// <reference types="react" />
2
1
  declare const _default: () => JSX.Element;
3
2
  /**
4
3
  * Basic sizes with title and online status
@@ -72,7 +72,7 @@ export interface ICalendarViewProps extends ICalendarProps {
72
72
  */
73
73
  isCaptionPanelVisible: boolean;
74
74
  /**
75
- * Функция измения состояние отображения панели для выбора месяца/года
75
+ * Функция изменения состояние отображения панели для выбора месяца/года
76
76
  */
77
77
  toggleCaptionPanel: () => void;
78
78
  }
@@ -1,4 +1,3 @@
1
- /// <reference types="react" />
2
1
  declare const _default: () => JSX.Element;
3
2
  /**
4
3
  * Basic
@@ -1,4 +1,3 @@
1
- /// <reference types="react" />
2
1
  declare const _default: () => JSX.Element;
3
2
  /**
4
3
  * Body
@@ -22,6 +22,7 @@ var __importDefault = (this && this.__importDefault) || function (mod) {
22
22
  return (mod && mod.__esModule) ? mod : { "default": mod };
23
23
  };
24
24
  exports.__esModule = true;
25
+ /* eslint-disable max-len */
25
26
  var React = __importStar(require("react"));
26
27
  var Card_1 = __importDefault(require("../Card"));
27
28
  /**
@@ -1,3 +1,2 @@
1
- /// <reference types="react" />
2
1
  declare const _default: () => JSX.Element;
3
2
  export default _default;
@@ -39,9 +39,10 @@ var colors = {
39
39
  lg: 'light',
40
40
  dr: 'dark'
41
41
  };
42
+ var text = 'Some quick example text to build on the card title and make up the bulk of the card\'s content.';
42
43
  function capitalize(s) {
43
44
  return s[0].toUpperCase() + s.slice(1);
44
45
  }
45
46
  exports["default"] = (function () { return (React.createElement("div", { style: { display: 'flex', flexWrap: 'wrap' } }, Object.values(colors).map(function (color) { return (React.createElement("div", { style: { marginRight: '30px', marginBottom: '30px' }, key: color },
46
47
  React.createElement(React.Fragment, null,
47
- React.createElement(Card_1["default"], { style: { width: '320px' }, header: 'Header', title: capitalize(color) + ' card title', borderColor: color }, "Some quick example text to build on the card title and make up the bulk of the card's content.")))); }))); });
48
+ React.createElement(Card_1["default"], { style: { width: '320px' }, header: 'Header', title: capitalize(color) + ' card title', borderColor: color }, text)))); }))); });
@@ -1,3 +1,2 @@
1
- /// <reference types="react" />
2
1
  declare const _default: () => JSX.Element;
3
2
  export default _default;
@@ -39,9 +39,10 @@ var colors = {
39
39
  lg: 'light',
40
40
  dr: 'dark'
41
41
  };
42
+ var text = 'Some quick example text to build on the card title and make up the bulk of the card\'s content.';
42
43
  function capitalize(s) {
43
44
  return s[0].toUpperCase() + s.slice(1);
44
45
  }
45
46
  exports["default"] = (function () { return (React.createElement("div", { style: { display: 'flex', flexWrap: 'wrap' } }, Object.values(colors).map(function (color) { return (React.createElement("div", { style: { marginRight: '30px', marginBottom: '30px' }, key: color },
46
47
  React.createElement(React.Fragment, null,
47
- React.createElement(Card_1["default"], { style: { width: '320px' }, header: 'Header', title: capitalize(color) + ' card title', color: color }, "Some quick example text to build on the card title and make up the bulk of the card's content.")))); }))); });
48
+ React.createElement(Card_1["default"], { style: { width: '320px' }, header: 'Header', title: capitalize(color) + ' card title', color: color }, text)))); }))); });
@@ -1,8 +1,2 @@
1
- /// <reference types="react" />
2
1
  declare const _default: () => JSX.Element;
3
- /**
4
- * Header and footer
5
- * @order 3
6
- * @col 12
7
- */
8
2
  export default _default;
@@ -30,13 +30,14 @@ var Card_1 = __importDefault(require("../Card"));
30
30
  * @order 3
31
31
  * @col 12
32
32
  */
33
+ var text = 'Some quick example text to build on the card title and make up the bulk of the card\'s content.';
33
34
  exports["default"] = (function () { return (React.createElement("div", { style: { display: 'grid', gridAutoFlow: 'column', gridGap: '30px' } },
34
35
  React.createElement(Card_1["default"], { title: 'Card title', header: 'Header' },
35
- "Some quick example text to build on the card title and make up the bulk of the card's content.",
36
+ text,
36
37
  React.createElement(form_1.Button, null, "Button")),
37
38
  React.createElement(Card_1["default"], { title: 'Card title', footer: 'Footer' },
38
- "Some quick example text to build on the card title and make up the bulk of the card's content.",
39
+ text,
39
40
  React.createElement(form_1.Button, null, "Button")),
40
41
  React.createElement(Card_1["default"], { title: 'Card title', header: 'Header', footer: 'Footer' },
41
- "Some quick example text to build on the card title and make up the bulk of the card's content.",
42
+ text,
42
43
  React.createElement(form_1.Button, null, "Button")))); });
@@ -1,8 +1,2 @@
1
- /// <reference types="react" />
2
1
  declare const _default: () => JSX.Element;
3
- /**
4
- * Hover image
5
- * @order 1
6
- * @col 8
7
- */
8
2
  export default _default;
@@ -30,8 +30,9 @@ var Card_1 = __importDefault(require("../Card"));
30
30
  * @order 1
31
31
  * @col 8
32
32
  */
33
+ var text = 'Some quick example text to build on the card title and make up the bulk of the card\'s content.';
33
34
  exports["default"] = (function () { return (React.createElement("div", { style: { display: 'flex', gridGap: '15px' } },
34
35
  React.createElement(Card_1["default"], { title: 'Card title', cover: 'https://i.ibb.co/rK9tsnJ/swamp.png' },
35
- "Some quick example text to build on the card title and make up the bulk of the card's content.",
36
+ text,
36
37
  React.createElement(form_1.Button, null, "Button")),
37
- React.createElement(Card_1["default"], { title: 'Card title', cover: 'https://i.ibb.co/rK9tsnJ/swamp.png' }, "Some quick example text to build on the card title and make up the bulk of the card's content."))); });
38
+ React.createElement(Card_1["default"], { title: 'Card title', cover: 'https://i.ibb.co/rK9tsnJ/swamp.png' }, text))); });
@@ -1,8 +1,2 @@
1
- /// <reference types="react" />
2
1
  declare const _default: () => JSX.Element;
3
- /**
4
- * Titles, text, and links
5
- * @order 2
6
- * @col 4
7
- */
8
2
  export default _default;
@@ -30,9 +30,10 @@ var Card_1 = __importDefault(require("../Card"));
30
30
  * @order 2
31
31
  * @col 4
32
32
  */
33
+ var text = 'Some quick example text to build on the card title and make up the bulk of the card\'s content.';
33
34
  exports["default"] = (function () { return (React.createElement(React.Fragment, null,
34
35
  React.createElement(Card_1["default"], { title: 'Card title' },
35
- "Some quick example text to build on the card title and make up the bulk of the card's content.",
36
+ text,
36
37
  React.createElement("div", { style: { display: 'flex', gridGap: '16px', padding: 0 } },
37
38
  React.createElement(form_1.Button, { link: true }, "Link"),
38
39
  React.createElement(form_1.Button, { link: true }, "Another link"))))); });
@@ -1,3 +1,2 @@
1
- /// <reference types="react" />
2
1
  declare const _default: () => JSX.Element;
3
2
  export default _default;
@@ -34,8 +34,9 @@ var orientations = {
34
34
  vr: 'vertical-reverse',
35
35
  hz: 'horizontal'
36
36
  };
37
+ var text = 'Some quick example text to build on the card title and make up the bulk of the card\'s content.';
37
38
  exports["default"] = (function () { return (React.createElement("div", { style: { display: 'grid', gridTemplateColumns: '1fr 1fr 2fr' } }, Object.values(orientations).map(function (orientation) { return (React.createElement("div", { style: { marginRight: '30px' }, key: orientation },
38
39
  React.createElement(React.Fragment, null,
39
40
  React.createElement(Card_1["default"], { title: 'Card title', orientation: orientation, cover: 'https://i.ibb.co/rK9tsnJ/swamp.png' },
40
- "Some quick example text to build on the card title and make up the bulk of the card's content.",
41
+ text,
41
42
  React.createElement("p", { style: { color: '#C0C0C0', fontSize: '12px' } }, "Last updated 3 mins ago"))))); }))); });
@@ -1,4 +1,3 @@
1
- /// <reference types="react" />
2
1
  declare const _default: () => JSX.Element;
3
2
  /**
4
3
  * Accordion mode
@@ -1,4 +1,3 @@
1
- /// <reference types="react" />
2
1
  declare const _default: () => JSX.Element;
3
2
  /**
4
3
  * Basic
@@ -1,4 +1,3 @@
1
- /// <reference types="react" />
2
1
  declare const _default: () => JSX.Element;
3
2
  /**
4
3
  * Borderless mode
@@ -1,4 +1,3 @@
1
- /// <reference types="react" />
2
1
  declare const _default: () => JSX.Element;
3
2
  /**
4
3
  * Disable CollapseItem
@@ -1,4 +1,3 @@
1
- /// <reference types="react" />
2
1
  declare const _default: () => JSX.Element;
3
2
  /**
4
3
  * Icon position left or right
@@ -1,4 +1,3 @@
1
- /// <reference types="react" />
2
1
  declare const _default: () => JSX.Element;
3
2
  /**
4
3
  * Custom icon
@@ -22,6 +22,7 @@ var __importDefault = (this && this.__importDefault) || function (mod) {
22
22
  return (mod && mod.__esModule) ? mod : { "default": mod };
23
23
  };
24
24
  exports.__esModule = true;
25
+ /* eslint-disable max-len */
25
26
  var React = __importStar(require("react"));
26
27
  var Collapse_1 = __importDefault(require("../Collapse"));
27
28
  var CollapseItem_1 = __importDefault(require("../CollapseItem"));
@@ -1,4 +1,3 @@
1
- /// <reference types="react" />
2
1
  declare const _default: () => JSX.Element;
3
2
  /**
4
3
  * Anonymous function every time you change state of Collapse
@@ -1,4 +1,3 @@
1
- /// <reference types="react" />
2
1
  declare const _default: () => JSX.Element;
3
2
  /**
4
3
  * Show or hide icon
@@ -1,4 +1,3 @@
1
- /// <reference types="react" />
2
1
  declare const _default: () => JSX.Element;
3
2
  /**
4
3
  * Basic table with title
@@ -1,3 +1,2 @@
1
- /// <reference types="react" />
2
1
  declare const _default: () => JSX.Element;
3
2
  export default _default;
@@ -31,9 +31,10 @@ var colors = {
31
31
  lg: 'light',
32
32
  dr: 'dark'
33
33
  };
34
+ var text = 'Some quick example text to build on the card title and make up the bulk of the card\'s content.';
34
35
  function capitalize(s) {
35
36
  return s[0].toUpperCase() + s.slice(1);
36
37
  }
37
38
  exports["default"] = (function () { return (React.createElement("div", { style: { display: 'flex', flexWrap: 'wrap' } }, Object.values(colors).map(function (color) { return (React.createElement("div", { style: { marginRight: '30px', marginBottom: '30px' }, key: color },
38
39
  React.createElement(React.Fragment, null,
39
- React.createElement(content_1.Card, { style: { width: '320px' }, header: 'Header', title: capitalize(color) + ' card title', color: color }, "Some quick example text to build on the card title and make up the bulk of the card's content.")))); }))); });
40
+ React.createElement(content_1.Card, { style: { width: '320px' }, header: 'Header', title: capitalize(color) + ' card title', color: color }, text)))); }))); });
@@ -1,4 +1,3 @@
1
- /// <reference types="react" />
2
1
  declare const _default: () => JSX.Element;
3
2
  /**
4
3
  * Table with controls
@@ -1,4 +1,3 @@
1
- /// <reference types="react" />
2
1
  declare const _default: () => JSX.Element;
3
2
  /**
4
3
  * Table with vertical layout