@hipay/hipay-material-ui 2.2.0 → 2.3.0-rc.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.
- package/CHANGELOG.md +8 -0
- package/HiAlertModal/HiAlertModal.js +5 -5
- package/HiAppBar/HiAppBar.js +4 -4
- package/HiBadge/HiBadge.js +2 -2
- package/HiBreadcrumb/HiStep.js +1 -1
- package/HiBreadcrumb/HiStepConnector.js +6 -6
- package/HiBreadcrumb/HiStepContent.js +1 -1
- package/HiBreadcrumb/HiStepIcon.js +1 -1
- package/HiBreadcrumb/HiStepLabel.js +1 -1
- package/HiBreadcrumb/HiStepper.js +1 -1
- package/HiButton/HiButton.js +41 -92
- package/HiCell/CellAddress.js +2 -2
- package/HiCell/CellDate.js +2 -2
- package/HiCell/CellIcon.js +2 -2
- package/HiCell/CellImage.js +2 -2
- package/HiCell/CellNumeric.js +2 -2
- package/HiCell/CellPinToAction.js +2 -2
- package/HiCell/CellRate.js +2 -2
- package/HiCell/CellSentinel.js +2 -2
- package/HiCell/CellSentinelScore.js +2 -2
- package/HiCell/CellText.js +5 -5
- package/HiCell/CellTextStyled.js +1 -1
- package/HiCheckbox/HiCheckbox.js +5 -5
- package/HiChip/HiChip.js +3 -3
- package/HiChip/HiChipSwitch.js +8 -8
- package/HiColoredLabel/HiColoredLabel.js +3 -3
- package/HiDatePicker/Caption.js +2 -2
- package/HiDatePicker/HiDatePicker.js +2 -2
- package/HiDatePicker/HiDatePickerMobile.js +2 -2
- package/HiDatePicker/HiDateRangePicker.js +2 -2
- package/HiDatePicker/HiDateRangeSelector.js +5 -4
- package/HiDatePicker/ListPicker.js +2 -2
- package/HiDatePicker/NavBar.js +2 -2
- package/HiDatePicker/Overlays/CustomOverlayLayout.js +2 -2
- package/HiDatePicker/Overlays/CustomOverlayLayoutWithoutFooter.js +2 -2
- package/HiDatePicker/Overlays/MonthPickerOverlay.js +3 -3
- package/HiDatePicker/Overlays/Overlay.js +2 -2
- package/HiDatePicker/Overlays/TimePickerOverlay.js +6 -6
- package/HiDatePicker/Overlays/YearPickerOverlay.js +3 -3
- package/HiDatePicker/stylesheet.js +1 -1
- package/HiDotsStepper/HiDot.js +2 -2
- package/HiDotsStepper/HiDotsStepper.js +6 -6
- package/HiExpansionPanel/HiExpansionPanel.js +36 -12
- package/HiForm/HiAddressField.js +7 -7
- package/HiForm/HiEmailField.js +3 -3
- package/HiForm/HiFormControl.js +8 -8
- package/HiForm/HiFormLabel.js +3 -3
- package/HiForm/HiInput.js +13 -13
- package/HiForm/HiPasswordField.js +9 -8
- package/HiForm/HiSearchField.js +5 -5
- package/HiForm/HiSlider.js +2 -2
- package/HiForm/HiTextField.js +5 -5
- package/HiForm/HiUpload.js +2 -2
- package/HiForm/HiUploadInput.js +3 -3
- package/HiIcon/HiIcon.js +2 -2
- package/HiIconButton/HiIconButton.js +2 -2
- package/HiLoader/HiLoader.js +2 -2
- package/HiMap/HiMap.js +7 -7
- package/HiMap/HiMapExpand.js +5 -5
- package/HiNotice/HiKPI.js +10 -9
- package/HiPaymentMeans/HiPaymentMeans.js +1 -1
- package/HiPdfReader/HiPdfReader.js +1 -1
- package/HiPin/HiPin.js +2 -2
- package/HiRadio/HiRadio.js +1 -1
- package/HiSelect/HiDynamicSelect.js +7 -7
- package/HiSelect/HiNestedSelect.js +14 -14
- package/HiSelect/HiNestedSelectContent.js +9 -9
- package/HiSelect/HiSelect.js +9 -9
- package/HiSelect/HiSelectContent.js +15 -15
- package/HiSelect/HiSelectInput.js +9 -9
- package/HiSelect/HiSelectMobile.js +2 -2
- package/HiSelect/HiSuggestSelect.js +1 -1
- package/HiSelectableList/HiSelectableList.js +2 -2
- package/HiSelectableList/HiSelectableListHierarchic.js +2 -2
- package/HiSelectableList/HiSelectableListItem.js +6 -6
- package/HiSwitch/HiSwitch.js +2 -2
- package/HiSwitch/HiSwitchState.js +2 -2
- package/HiTable/HiTable.js +5 -5
- package/HiTable/HiTableHeader.js +3 -3
- package/HiTable/HiTableRow.js +7 -6
- package/es/HiAlertModal/HiAlertModal.js +1 -1
- package/es/HiAppBar/HiAppBar.js +1 -1
- package/es/HiBadge/HiBadge.js +1 -1
- package/es/HiBreadcrumb/HiStep.js +1 -1
- package/es/HiBreadcrumb/HiStepConnector.js +3 -3
- package/es/HiBreadcrumb/HiStepContent.js +1 -1
- package/es/HiBreadcrumb/HiStepIcon.js +1 -1
- package/es/HiBreadcrumb/HiStepLabel.js +1 -1
- package/es/HiBreadcrumb/HiStepper.js +1 -1
- package/es/HiButton/HiButton.js +56 -82
- package/es/HiCell/CellAddress.js +1 -1
- package/es/HiCell/CellDate.js +1 -1
- package/es/HiCell/CellIcon.js +1 -1
- package/es/HiCell/CellImage.js +1 -1
- package/es/HiCell/CellNumeric.js +1 -1
- package/es/HiCell/CellPinToAction.js +1 -1
- package/es/HiCell/CellRate.js +1 -1
- package/es/HiCell/CellSentinel.js +1 -1
- package/es/HiCell/CellSentinelScore.js +1 -1
- package/es/HiCell/CellText.js +1 -1
- package/es/HiCell/CellTextStyled.js +1 -1
- package/es/HiCheckbox/HiCheckbox.js +1 -1
- package/es/HiChip/HiChip.js +2 -2
- package/es/HiChip/HiChipSwitch.js +2 -2
- package/es/HiColoredLabel/HiColoredLabel.js +2 -2
- package/es/HiDatePicker/Caption.js +1 -1
- package/es/HiDatePicker/HiDatePicker.js +1 -1
- package/es/HiDatePicker/HiDatePickerMobile.js +1 -1
- package/es/HiDatePicker/HiDateRangePicker.js +1 -1
- package/es/HiDatePicker/HiDateRangeSelector.js +4 -3
- package/es/HiDatePicker/ListPicker.js +1 -1
- package/es/HiDatePicker/NavBar.js +1 -1
- package/es/HiDatePicker/Overlays/CustomOverlayLayout.js +1 -1
- package/es/HiDatePicker/Overlays/CustomOverlayLayoutWithoutFooter.js +1 -1
- package/es/HiDatePicker/Overlays/Overlay.js +1 -1
- package/es/HiDatePicker/Overlays/TimePickerOverlay.js +1 -1
- package/es/HiDatePicker/stylesheet.js +1 -1
- package/es/HiDotsStepper/HiDot.js +1 -1
- package/es/HiDotsStepper/HiDotsStepper.js +1 -1
- package/es/HiExpansionPanel/HiExpansionPanel.js +34 -9
- package/es/HiForm/HiFormControl.js +1 -1
- package/es/HiForm/HiFormLabel.js +2 -2
- package/es/HiForm/HiInput.js +1 -1
- package/es/HiForm/HiPasswordField.js +5 -4
- package/es/HiForm/HiSlider.js +1 -1
- package/es/HiForm/HiUpload.js +1 -1
- package/es/HiForm/HiUploadInput.js +2 -2
- package/es/HiIcon/HiIcon.js +1 -1
- package/es/HiIconButton/HiIconButton.js +2 -2
- package/es/HiLoader/HiLoader.js +1 -1
- package/es/HiMap/HiMap.js +1 -1
- package/es/HiMap/HiMapExpand.js +1 -1
- package/es/HiNotice/HiKPI.js +7 -6
- package/es/HiPaymentMeans/HiPaymentMeans.js +1 -1
- package/es/HiPdfReader/HiPdfReader.js +1 -1
- package/es/HiPin/HiPin.js +2 -2
- package/es/HiRadio/HiRadio.js +1 -1
- package/es/HiSelect/HiNestedSelect.js +1 -1
- package/es/HiSelect/HiSelect.js +1 -1
- package/es/HiSelect/HiSelectContent.js +1 -1
- package/es/HiSelect/HiSelectInput.js +1 -1
- package/es/HiSelect/HiSelectMobile.js +1 -1
- package/es/HiSelect/HiSuggestSelect.js +1 -1
- package/es/HiSelectableList/HiSelectableList.js +1 -1
- package/es/HiSelectableList/HiSelectableListHierarchic.js +1 -1
- package/es/HiSelectableList/HiSelectableListItem.js +1 -1
- package/es/HiSwitch/HiSwitch.js +1 -1
- package/es/HiSwitch/HiSwitchState.js +1 -1
- package/es/HiTable/HiTable.js +1 -1
- package/es/HiTable/HiTableHeader.js +2 -2
- package/es/HiTable/HiTableRow.js +3 -2
- package/es/hi-svg-icons/HiAccount.js +1 -1
- package/es/hi-svg-icons/HiActivity.js +1 -1
- package/es/hi-svg-icons/HiAll.js +1 -1
- package/es/hi-svg-icons/HiBilling.js +1 -1
- package/es/hi-svg-icons/HiCatalog.js +1 -1
- package/es/hi-svg-icons/HiCustomer.js +1 -1
- package/es/hi-svg-icons/HiFinance.js +1 -1
- package/es/hi-svg-icons/HiPermission.js +1 -1
- package/es/hi-svg-icons/HiRoute.js +1 -1
- package/es/hi-svg-icons/HiSettlement.js +1 -1
- package/es/hi-svg-icons/HiTransaction.js +1 -1
- package/es/hi-svg-icons/HiUser.js +1 -1
- package/es/hi-svg-icons/HiWidget.js +1 -1
- package/es/index.js +0 -2
- package/es/styles/createMixins.js +4 -4
- package/es/styles/spacing.js +2 -5
- package/es/test-utils/getClasses.js +2 -16
- package/es/withMobileDialog/withMobileDialog.js +1 -1
- package/hi-svg-icons/HiAccount.js +1 -1
- package/hi-svg-icons/HiActivity.js +1 -1
- package/hi-svg-icons/HiAll.js +1 -1
- package/hi-svg-icons/HiBilling.js +1 -1
- package/hi-svg-icons/HiCatalog.js +1 -1
- package/hi-svg-icons/HiCustomer.js +1 -1
- package/hi-svg-icons/HiFinance.js +1 -1
- package/hi-svg-icons/HiPermission.js +1 -1
- package/hi-svg-icons/HiRoute.js +1 -1
- package/hi-svg-icons/HiSettlement.js +1 -1
- package/hi-svg-icons/HiTransaction.js +1 -1
- package/hi-svg-icons/HiUser.js +1 -1
- package/hi-svg-icons/HiWidget.js +1 -1
- package/index.es.js +1 -3
- package/index.js +1 -17
- package/package.json +4 -5
- package/styles/createMixins.js +4 -4
- package/styles/spacing.js +5 -4
- package/test-utils/getClasses.js +5 -29
- package/withMobileDialog/withMobileDialog.js +1 -1
- package/es/withWidth/index.js +0 -2
- package/es/withWidth/withWidth.js +0 -176
- package/withWidth/index.js +0 -27
- package/withWidth/withWidth.js +0 -229
|
@@ -2,7 +2,7 @@ import _extends from "@babel/runtime/helpers/extends";
|
|
|
2
2
|
import _objectWithoutProperties from "@babel/runtime/helpers/objectWithoutProperties";
|
|
3
3
|
import React from 'react';
|
|
4
4
|
import pure from 'recompose/pure';
|
|
5
|
-
import { withStyles } from '
|
|
5
|
+
import { withStyles } from '@material-ui/core/styles';
|
|
6
6
|
/**
|
|
7
7
|
* @ignore - internal component.
|
|
8
8
|
*/
|
package/es/index.js
CHANGED
|
@@ -13,7 +13,6 @@ export { default as HiMap } from './HiMap/HiMap';
|
|
|
13
13
|
export { default as HiMapExpand } from './HiMap/HiMapExpand';
|
|
14
14
|
export { default as HiTextField } from './HiForm/HiTextField';
|
|
15
15
|
export { default as HiPasswordField } from './HiForm/HiPasswordField';
|
|
16
|
-
export { default as HiPdfReader } from './HiPdfReader/HiPdfReader';
|
|
17
16
|
export { default as HiSlider } from './HiForm/HiSlider';
|
|
18
17
|
export { default as HiSwitch } from './HiSwitch';
|
|
19
18
|
export { default as HiSwitchState } from './HiSwitch/HiSwitchState';
|
|
@@ -21,7 +20,6 @@ export { default as HiTable } from './HiTable/HiTable';
|
|
|
21
20
|
export { default as HiDotsStepper } from './HiDotsStepper/HiDotsStepper';
|
|
22
21
|
export { default as HiDot } from './HiDotsStepper/HiDot';
|
|
23
22
|
export { default as withMobileDialog } from './withMobileDialog';
|
|
24
|
-
export { default as withWidth } from './withWidth';
|
|
25
23
|
export { default as HiDatePicker } from './HiDatePicker/HiDatePicker';
|
|
26
24
|
export { default as HiDateRangePicker } from './HiDatePicker/HiDateRangePicker';
|
|
27
25
|
export { default as HiDateRangeSelector } from './HiDatePicker/HiDateRangeSelector';
|
|
@@ -3,12 +3,12 @@ export default function createMixins(breakpoints, spacing, mixins) {
|
|
|
3
3
|
return _objectSpread({
|
|
4
4
|
gutters: (styles = {}) => {
|
|
5
5
|
return _objectSpread({
|
|
6
|
-
paddingLeft: spacing
|
|
7
|
-
paddingRight: spacing
|
|
6
|
+
paddingLeft: spacing(4),
|
|
7
|
+
paddingRight: spacing(4)
|
|
8
8
|
}, styles, {
|
|
9
9
|
[breakpoints.up('sm')]: _objectSpread({
|
|
10
|
-
paddingLeft: spacing
|
|
11
|
-
paddingRight: spacing
|
|
10
|
+
paddingLeft: spacing(6),
|
|
11
|
+
paddingRight: spacing(6)
|
|
12
12
|
}, styles[breakpoints.up('sm')])
|
|
13
13
|
});
|
|
14
14
|
},
|
package/es/styles/spacing.js
CHANGED
|
@@ -1,17 +1,3 @@
|
|
|
1
|
-
import
|
|
2
|
-
import * as ns from 'react-jss/lib/ns';
|
|
3
|
-
import { SheetsRegistry } from 'jss';
|
|
4
|
-
import createShallow from './createShallow';
|
|
5
|
-
import { sheetsManager } from '../styles/withStyles';
|
|
6
|
-
const shallow = createShallow(); // Helper function to extract the classes from a styleSheet.
|
|
1
|
+
import { getClasses } from '@material-ui/core/test-utils'; // Helper function to extract the classes from a styleSheet.
|
|
7
2
|
|
|
8
|
-
export default
|
|
9
|
-
const sheetsRegistry = new SheetsRegistry();
|
|
10
|
-
sheetsManager.clear();
|
|
11
|
-
shallow(element, _objectSpread({}, options, {
|
|
12
|
-
context: _objectSpread({
|
|
13
|
-
[ns.sheetsRegistry]: sheetsRegistry
|
|
14
|
-
}, options.context)
|
|
15
|
-
}));
|
|
16
|
-
return sheetsRegistry.registry[0].classes;
|
|
17
|
-
}
|
|
3
|
+
export default getClasses;
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import _extends from "@babel/runtime/helpers/extends";
|
|
2
2
|
import React from 'react';
|
|
3
3
|
import PropTypes from 'prop-types';
|
|
4
|
-
import withWidth, { isWidthDown } from '
|
|
4
|
+
import withWidth, { isWidthDown } from '@material-ui/core/withWidth';
|
|
5
5
|
/**
|
|
6
6
|
* Dialog will responsively be full screen *at or below* the given breakpoint
|
|
7
7
|
* (defaults to 'sm' for mobile devices).
|
|
@@ -15,7 +15,7 @@ var _react = _interopRequireDefault(require("react"));
|
|
|
15
15
|
|
|
16
16
|
var _pure = _interopRequireDefault(require("recompose/pure"));
|
|
17
17
|
|
|
18
|
-
var _styles = require("
|
|
18
|
+
var _styles = require("@material-ui/core/styles");
|
|
19
19
|
|
|
20
20
|
/**
|
|
21
21
|
* @ignore - internal component.
|
|
@@ -15,7 +15,7 @@ var _react = _interopRequireDefault(require("react"));
|
|
|
15
15
|
|
|
16
16
|
var _pure = _interopRequireDefault(require("recompose/pure"));
|
|
17
17
|
|
|
18
|
-
var _styles = require("
|
|
18
|
+
var _styles = require("@material-ui/core/styles");
|
|
19
19
|
|
|
20
20
|
/**
|
|
21
21
|
* @ignore - internal component.
|
package/hi-svg-icons/HiAll.js
CHANGED
|
@@ -15,7 +15,7 @@ var _react = _interopRequireDefault(require("react"));
|
|
|
15
15
|
|
|
16
16
|
var _pure = _interopRequireDefault(require("recompose/pure"));
|
|
17
17
|
|
|
18
|
-
var _styles = require("
|
|
18
|
+
var _styles = require("@material-ui/core/styles");
|
|
19
19
|
|
|
20
20
|
var _ref = _react.default.createElement("path", {
|
|
21
21
|
fill: "none",
|
|
@@ -15,7 +15,7 @@ var _react = _interopRequireDefault(require("react"));
|
|
|
15
15
|
|
|
16
16
|
var _pure = _interopRequireDefault(require("recompose/pure"));
|
|
17
17
|
|
|
18
|
-
var _styles = require("
|
|
18
|
+
var _styles = require("@material-ui/core/styles");
|
|
19
19
|
|
|
20
20
|
/**
|
|
21
21
|
* @ignore - internal component.
|
|
@@ -15,7 +15,7 @@ var _react = _interopRequireDefault(require("react"));
|
|
|
15
15
|
|
|
16
16
|
var _pure = _interopRequireDefault(require("recompose/pure"));
|
|
17
17
|
|
|
18
|
-
var _styles = require("
|
|
18
|
+
var _styles = require("@material-ui/core/styles");
|
|
19
19
|
|
|
20
20
|
/**
|
|
21
21
|
* @ignore - internal component.
|
|
@@ -15,7 +15,7 @@ var _react = _interopRequireDefault(require("react"));
|
|
|
15
15
|
|
|
16
16
|
var _pure = _interopRequireDefault(require("recompose/pure"));
|
|
17
17
|
|
|
18
|
-
var _styles = require("
|
|
18
|
+
var _styles = require("@material-ui/core/styles");
|
|
19
19
|
|
|
20
20
|
/**
|
|
21
21
|
* @ignore - internal component.
|
|
@@ -15,7 +15,7 @@ var _react = _interopRequireDefault(require("react"));
|
|
|
15
15
|
|
|
16
16
|
var _pure = _interopRequireDefault(require("recompose/pure"));
|
|
17
17
|
|
|
18
|
-
var _styles = require("
|
|
18
|
+
var _styles = require("@material-ui/core/styles");
|
|
19
19
|
|
|
20
20
|
/**
|
|
21
21
|
* @ignore - internal component.
|
|
@@ -15,7 +15,7 @@ var _react = _interopRequireDefault(require("react"));
|
|
|
15
15
|
|
|
16
16
|
var _pure = _interopRequireDefault(require("recompose/pure"));
|
|
17
17
|
|
|
18
|
-
var _styles = require("
|
|
18
|
+
var _styles = require("@material-ui/core/styles");
|
|
19
19
|
|
|
20
20
|
/**
|
|
21
21
|
* @ignore - internal component.
|
package/hi-svg-icons/HiRoute.js
CHANGED
|
@@ -15,7 +15,7 @@ var _react = _interopRequireDefault(require("react"));
|
|
|
15
15
|
|
|
16
16
|
var _pure = _interopRequireDefault(require("recompose/pure"));
|
|
17
17
|
|
|
18
|
-
var _styles = require("
|
|
18
|
+
var _styles = require("@material-ui/core/styles");
|
|
19
19
|
|
|
20
20
|
/**
|
|
21
21
|
* @ignore - internal component.
|
|
@@ -15,7 +15,7 @@ var _react = _interopRequireDefault(require("react"));
|
|
|
15
15
|
|
|
16
16
|
var _pure = _interopRequireDefault(require("recompose/pure"));
|
|
17
17
|
|
|
18
|
-
var _styles = require("
|
|
18
|
+
var _styles = require("@material-ui/core/styles");
|
|
19
19
|
|
|
20
20
|
/**
|
|
21
21
|
* @ignore - internal component.
|
|
@@ -15,7 +15,7 @@ var _react = _interopRequireDefault(require("react"));
|
|
|
15
15
|
|
|
16
16
|
var _pure = _interopRequireDefault(require("recompose/pure"));
|
|
17
17
|
|
|
18
|
-
var _styles = require("
|
|
18
|
+
var _styles = require("@material-ui/core/styles");
|
|
19
19
|
|
|
20
20
|
/**
|
|
21
21
|
* @ignore - internal component.
|
package/hi-svg-icons/HiUser.js
CHANGED
|
@@ -15,7 +15,7 @@ var _react = _interopRequireDefault(require("react"));
|
|
|
15
15
|
|
|
16
16
|
var _pure = _interopRequireDefault(require("recompose/pure"));
|
|
17
17
|
|
|
18
|
-
var _styles = require("
|
|
18
|
+
var _styles = require("@material-ui/core/styles");
|
|
19
19
|
|
|
20
20
|
/**
|
|
21
21
|
* @ignore - internal component.
|
package/hi-svg-icons/HiWidget.js
CHANGED
|
@@ -15,7 +15,7 @@ var _react = _interopRequireDefault(require("react"));
|
|
|
15
15
|
|
|
16
16
|
var _pure = _interopRequireDefault(require("recompose/pure"));
|
|
17
17
|
|
|
18
|
-
var _styles = require("
|
|
18
|
+
var _styles = require("@material-ui/core/styles");
|
|
19
19
|
|
|
20
20
|
var _ref = _react.default.createElement("path", {
|
|
21
21
|
fill: "none",
|
package/index.es.js
CHANGED
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
/** @license HiPay-Material-UI v2.
|
|
1
|
+
/** @license HiPay-Material-UI v2.3.0-rc.2
|
|
2
2
|
*
|
|
3
3
|
* This source code is licensed under the MIT license found in the
|
|
4
4
|
* LICENSE file in the root directory of this source tree.
|
|
@@ -18,7 +18,6 @@ export { default as HiMap } from './HiMap/HiMap';
|
|
|
18
18
|
export { default as HiMapExpand } from './HiMap/HiMapExpand';
|
|
19
19
|
export { default as HiTextField } from './HiForm/HiTextField';
|
|
20
20
|
export { default as HiPasswordField } from './HiForm/HiPasswordField';
|
|
21
|
-
export { default as HiPdfReader } from './HiPdfReader/HiPdfReader';
|
|
22
21
|
export { default as HiSlider } from './HiForm/HiSlider';
|
|
23
22
|
export { default as HiSwitch } from './HiSwitch';
|
|
24
23
|
export { default as HiSwitchState } from './HiSwitch/HiSwitchState';
|
|
@@ -26,7 +25,6 @@ export { default as HiTable } from './HiTable/HiTable';
|
|
|
26
25
|
export { default as HiDotsStepper } from './HiDotsStepper/HiDotsStepper';
|
|
27
26
|
export { default as HiDot } from './HiDotsStepper/HiDot';
|
|
28
27
|
export { default as withMobileDialog } from './withMobileDialog';
|
|
29
|
-
export { default as withWidth } from './withWidth';
|
|
30
28
|
export { default as HiDatePicker } from './HiDatePicker/HiDatePicker';
|
|
31
29
|
export { default as HiDateRangePicker } from './HiDatePicker/HiDateRangePicker';
|
|
32
30
|
export { default as HiDateRangeSelector } from './HiDatePicker/HiDateRangeSelector';
|
package/index.js
CHANGED
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
/** @license HiPay-Material-UI v2.
|
|
1
|
+
/** @license HiPay-Material-UI v2.3.0-rc.2
|
|
2
2
|
*
|
|
3
3
|
* This source code is licensed under the MIT license found in the
|
|
4
4
|
* LICENSE file in the root directory of this source tree.
|
|
@@ -136,12 +136,6 @@ Object.defineProperty(exports, "HiPasswordField", {
|
|
|
136
136
|
return _HiPasswordField.default;
|
|
137
137
|
}
|
|
138
138
|
});
|
|
139
|
-
Object.defineProperty(exports, "HiPdfReader", {
|
|
140
|
-
enumerable: true,
|
|
141
|
-
get: function get() {
|
|
142
|
-
return _HiPdfReader.default;
|
|
143
|
-
}
|
|
144
|
-
});
|
|
145
139
|
Object.defineProperty(exports, "HiSlider", {
|
|
146
140
|
enumerable: true,
|
|
147
141
|
get: function get() {
|
|
@@ -184,12 +178,6 @@ Object.defineProperty(exports, "withMobileDialog", {
|
|
|
184
178
|
return _withMobileDialog.default;
|
|
185
179
|
}
|
|
186
180
|
});
|
|
187
|
-
Object.defineProperty(exports, "withWidth", {
|
|
188
|
-
enumerable: true,
|
|
189
|
-
get: function get() {
|
|
190
|
-
return _withWidth.default;
|
|
191
|
-
}
|
|
192
|
-
});
|
|
193
181
|
Object.defineProperty(exports, "HiDatePicker", {
|
|
194
182
|
enumerable: true,
|
|
195
183
|
get: function get() {
|
|
@@ -245,8 +233,6 @@ var _HiTextField = _interopRequireDefault(require("./HiForm/HiTextField"));
|
|
|
245
233
|
|
|
246
234
|
var _HiPasswordField = _interopRequireDefault(require("./HiForm/HiPasswordField"));
|
|
247
235
|
|
|
248
|
-
var _HiPdfReader = _interopRequireDefault(require("./HiPdfReader/HiPdfReader"));
|
|
249
|
-
|
|
250
236
|
var _HiSlider = _interopRequireDefault(require("./HiForm/HiSlider"));
|
|
251
237
|
|
|
252
238
|
var _HiSwitch = _interopRequireDefault(require("./HiSwitch"));
|
|
@@ -261,8 +247,6 @@ var _HiDot = _interopRequireDefault(require("./HiDotsStepper/HiDot"));
|
|
|
261
247
|
|
|
262
248
|
var _withMobileDialog = _interopRequireDefault(require("./withMobileDialog"));
|
|
263
249
|
|
|
264
|
-
var _withWidth = _interopRequireDefault(require("./withWidth"));
|
|
265
|
-
|
|
266
250
|
var _HiDatePicker = _interopRequireDefault(require("./HiDatePicker/HiDatePicker"));
|
|
267
251
|
|
|
268
252
|
var _HiDateRangePicker = _interopRequireDefault(require("./HiDatePicker/HiDateRangePicker"));
|
package/package.json
CHANGED
|
@@ -2,7 +2,7 @@
|
|
|
2
2
|
"name": "@hipay/hipay-material-ui",
|
|
3
3
|
"private": false,
|
|
4
4
|
"author": "HiPay PSYCHE Team",
|
|
5
|
-
"version": "2.
|
|
5
|
+
"version": "2.3.0-rc.2",
|
|
6
6
|
"description": "React components that implement Google's Material Design.",
|
|
7
7
|
"keywords": [
|
|
8
8
|
"react",
|
|
@@ -27,8 +27,8 @@
|
|
|
27
27
|
},
|
|
28
28
|
"dependencies": {
|
|
29
29
|
"@babel/runtime": "7.0.0",
|
|
30
|
-
"@material-ui/core": "
|
|
31
|
-
"@material-ui/icons": "
|
|
30
|
+
"@material-ui/core": "4.4.3",
|
|
31
|
+
"@material-ui/icons": "4.4.3",
|
|
32
32
|
"@types/jss": "^9.5.3",
|
|
33
33
|
"@types/react-transition-group": "^2.0.8",
|
|
34
34
|
"brcast": "^3.0.1",
|
|
@@ -39,7 +39,6 @@
|
|
|
39
39
|
"dom-helpers": "^3.2.1",
|
|
40
40
|
"hoist-non-react-statics": "^2.5.0",
|
|
41
41
|
"is-plain-object": "^2.0.4",
|
|
42
|
-
"jss": "^9.8.7",
|
|
43
42
|
"jss-camel-case": "^6.0.0",
|
|
44
43
|
"jss-default-unit": "^8.0.2",
|
|
45
44
|
"jss-global": "^3.0.0",
|
|
@@ -48,7 +47,7 @@
|
|
|
48
47
|
"jss-vendor-prefixer": "^8.0.1",
|
|
49
48
|
"keycode": "^2.1.9",
|
|
50
49
|
"leaflet": "^1.5.1",
|
|
51
|
-
"mdi-material-ui": "^
|
|
50
|
+
"mdi-material-ui": "^6.7.0",
|
|
52
51
|
"moment": "^2.22.2",
|
|
53
52
|
"moment-timezone": "^0.5.23",
|
|
54
53
|
"normalize-scroll-left": "^0.1.2",
|
package/styles/createMixins.js
CHANGED
|
@@ -18,11 +18,11 @@ function createMixins(breakpoints, spacing, mixins) {
|
|
|
18
18
|
gutters: function gutters() {
|
|
19
19
|
var styles = arguments.length > 0 && arguments[0] !== undefined ? arguments[0] : {};
|
|
20
20
|
return (0, _extends3.default)({
|
|
21
|
-
paddingLeft: spacing
|
|
22
|
-
paddingRight: spacing
|
|
21
|
+
paddingLeft: spacing(4),
|
|
22
|
+
paddingRight: spacing(4)
|
|
23
23
|
}, styles, (0, _defineProperty2.default)({}, breakpoints.up('sm'), (0, _extends3.default)({
|
|
24
|
-
paddingLeft: spacing
|
|
25
|
-
paddingRight: spacing
|
|
24
|
+
paddingLeft: spacing(6),
|
|
25
|
+
paddingRight: spacing(6)
|
|
26
26
|
}, styles[breakpoints.up('sm')])));
|
|
27
27
|
},
|
|
28
28
|
toolbar: (_toolbar = {
|
package/styles/spacing.js
CHANGED
|
@@ -4,10 +4,11 @@ Object.defineProperty(exports, "__esModule", {
|
|
|
4
4
|
value: true
|
|
5
5
|
});
|
|
6
6
|
exports.default = void 0;
|
|
7
|
-
|
|
8
|
-
|
|
9
|
-
|
|
10
|
-
|
|
7
|
+
|
|
8
|
+
var spacing = function spacing() {
|
|
9
|
+
var n = arguments.length > 0 && arguments[0] !== undefined ? arguments[0] : 1;
|
|
10
|
+
return n * 4;
|
|
11
11
|
};
|
|
12
|
+
|
|
12
13
|
var _default = spacing;
|
|
13
14
|
exports.default = _default;
|
package/test-utils/getClasses.js
CHANGED
|
@@ -1,36 +1,12 @@
|
|
|
1
1
|
"use strict";
|
|
2
2
|
|
|
3
|
-
var _interopRequireWildcard = require("@babel/runtime/helpers/interopRequireWildcard");
|
|
4
|
-
|
|
5
|
-
var _interopRequireDefault = require("@babel/runtime/helpers/interopRequireDefault");
|
|
6
|
-
|
|
7
3
|
Object.defineProperty(exports, "__esModule", {
|
|
8
4
|
value: true
|
|
9
5
|
});
|
|
10
|
-
exports.default =
|
|
11
|
-
|
|
12
|
-
var _defineProperty2 = _interopRequireDefault(require("@babel/runtime/helpers/defineProperty"));
|
|
13
|
-
|
|
14
|
-
var _extends3 = _interopRequireDefault(require("@babel/runtime/helpers/extends"));
|
|
15
|
-
|
|
16
|
-
var ns = _interopRequireWildcard(require("react-jss/lib/ns"));
|
|
17
|
-
|
|
18
|
-
var _jss = require("jss");
|
|
19
|
-
|
|
20
|
-
var _createShallow = _interopRequireDefault(require("./createShallow"));
|
|
21
|
-
|
|
22
|
-
var _withStyles = require("../styles/withStyles");
|
|
23
|
-
|
|
24
|
-
var shallow = (0, _createShallow.default)(); // Helper function to extract the classes from a styleSheet.
|
|
25
|
-
|
|
26
|
-
function getClasses(element) {
|
|
27
|
-
var options = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : {};
|
|
28
|
-
var sheetsRegistry = new _jss.SheetsRegistry();
|
|
6
|
+
exports.default = void 0;
|
|
29
7
|
|
|
30
|
-
|
|
8
|
+
var _testUtils = require("@material-ui/core/test-utils");
|
|
31
9
|
|
|
32
|
-
|
|
33
|
-
|
|
34
|
-
|
|
35
|
-
return sheetsRegistry.registry[0].classes;
|
|
36
|
-
}
|
|
10
|
+
// Helper function to extract the classes from a styleSheet.
|
|
11
|
+
var _default = _testUtils.getClasses;
|
|
12
|
+
exports.default = _default;
|
|
@@ -15,7 +15,7 @@ var _react = _interopRequireDefault(require("react"));
|
|
|
15
15
|
|
|
16
16
|
var _propTypes = _interopRequireDefault(require("prop-types"));
|
|
17
17
|
|
|
18
|
-
var _withWidth = _interopRequireWildcard(require("
|
|
18
|
+
var _withWidth = _interopRequireWildcard(require("@material-ui/core/withWidth"));
|
|
19
19
|
|
|
20
20
|
/**
|
|
21
21
|
* Dialog will responsively be full screen *at or below* the given breakpoint
|
package/es/withWidth/index.js
DELETED
|
@@ -1,176 +0,0 @@
|
|
|
1
|
-
import _extends from "@babel/runtime/helpers/extends";
|
|
2
|
-
import _objectSpread from "@babel/runtime/helpers/objectSpread";
|
|
3
|
-
import _objectWithoutProperties from "@babel/runtime/helpers/objectWithoutProperties";
|
|
4
|
-
|
|
5
|
-
/* eslint-disable react/no-did-mount-set-state */
|
|
6
|
-
import React from 'react';
|
|
7
|
-
import PropTypes from 'prop-types';
|
|
8
|
-
import EventListener from 'react-event-listener';
|
|
9
|
-
import debounce from 'debounce'; // < 1kb payload overhead when lodash/debounce is > 3kb.
|
|
10
|
-
|
|
11
|
-
import wrapDisplayName from 'recompose/wrapDisplayName';
|
|
12
|
-
import hoistNonReactStatics from 'hoist-non-react-statics';
|
|
13
|
-
import withTheme from '../styles/withTheme';
|
|
14
|
-
import { keys as breakpointKeys } from '../styles/createBreakpoints';
|
|
15
|
-
import getThemeProps from '../styles/getThemeProps'; // By default, returns true if screen width is the same or greater than the given breakpoint.
|
|
16
|
-
|
|
17
|
-
export const isWidthUp = (breakpoint, width, inclusive = true) => {
|
|
18
|
-
if (inclusive) {
|
|
19
|
-
return breakpointKeys.indexOf(breakpoint) <= breakpointKeys.indexOf(width);
|
|
20
|
-
}
|
|
21
|
-
|
|
22
|
-
return breakpointKeys.indexOf(breakpoint) < breakpointKeys.indexOf(width);
|
|
23
|
-
}; // By default, returns true if screen width is the same or less than the given breakpoint.
|
|
24
|
-
|
|
25
|
-
export const isWidthDown = (breakpoint, width, inclusive = true) => {
|
|
26
|
-
if (inclusive) {
|
|
27
|
-
return breakpointKeys.indexOf(width) <= breakpointKeys.indexOf(breakpoint);
|
|
28
|
-
}
|
|
29
|
-
|
|
30
|
-
return breakpointKeys.indexOf(width) < breakpointKeys.indexOf(breakpoint);
|
|
31
|
-
};
|
|
32
|
-
|
|
33
|
-
const withWidth = (options = {}) => Component => {
|
|
34
|
-
const {
|
|
35
|
-
withTheme: withThemeOption = false,
|
|
36
|
-
noSSR = false,
|
|
37
|
-
initialWidth: initialWidthOption,
|
|
38
|
-
resizeInterval = 166 // Corresponds to 10 frames at 60 Hz.
|
|
39
|
-
|
|
40
|
-
} = options;
|
|
41
|
-
|
|
42
|
-
class WithWidth extends React.Component {
|
|
43
|
-
constructor(props) {
|
|
44
|
-
super(props);
|
|
45
|
-
this.handleResize = debounce(() => {
|
|
46
|
-
const width = this.getWidth();
|
|
47
|
-
|
|
48
|
-
if (width !== this.state.width) {
|
|
49
|
-
this.setState({
|
|
50
|
-
width
|
|
51
|
-
});
|
|
52
|
-
}
|
|
53
|
-
}, resizeInterval);
|
|
54
|
-
this.state = {
|
|
55
|
-
width: undefined
|
|
56
|
-
};
|
|
57
|
-
|
|
58
|
-
if (noSSR) {
|
|
59
|
-
this.state.width = this.getWidth();
|
|
60
|
-
}
|
|
61
|
-
}
|
|
62
|
-
|
|
63
|
-
componentDidMount() {
|
|
64
|
-
const width = this.getWidth();
|
|
65
|
-
|
|
66
|
-
if (width !== this.state.width) {
|
|
67
|
-
this.setState({
|
|
68
|
-
width
|
|
69
|
-
});
|
|
70
|
-
}
|
|
71
|
-
}
|
|
72
|
-
|
|
73
|
-
componentWillUnmount() {
|
|
74
|
-
this.handleResize.clear();
|
|
75
|
-
}
|
|
76
|
-
|
|
77
|
-
getWidth(innerWidth = window.innerWidth) {
|
|
78
|
-
const breakpoints = this.props.theme.breakpoints;
|
|
79
|
-
let width = null;
|
|
80
|
-
/**
|
|
81
|
-
* Start with the slowest value as low end devices often have a small screen.
|
|
82
|
-
*
|
|
83
|
-
* innerWidth |xs sm md lg xl
|
|
84
|
-
* |-------|-------|-------|-------|------>
|
|
85
|
-
* width | xs | sm | md | lg | xl
|
|
86
|
-
*/
|
|
87
|
-
|
|
88
|
-
let index = 1;
|
|
89
|
-
|
|
90
|
-
while (width === null && index < breakpointKeys.length) {
|
|
91
|
-
const currentWidth = breakpointKeys[index]; // @media are inclusive, so reproduce the behavior here.
|
|
92
|
-
|
|
93
|
-
if (innerWidth < breakpoints.values[currentWidth]) {
|
|
94
|
-
width = breakpointKeys[index - 1];
|
|
95
|
-
break;
|
|
96
|
-
}
|
|
97
|
-
|
|
98
|
-
index += 1;
|
|
99
|
-
}
|
|
100
|
-
|
|
101
|
-
width = width || 'xl';
|
|
102
|
-
return width;
|
|
103
|
-
}
|
|
104
|
-
|
|
105
|
-
render() {
|
|
106
|
-
const _this$props = this.props,
|
|
107
|
-
{
|
|
108
|
-
initialWidth,
|
|
109
|
-
theme,
|
|
110
|
-
width
|
|
111
|
-
} = _this$props,
|
|
112
|
-
other = _objectWithoutProperties(_this$props, ["initialWidth", "theme", "width"]);
|
|
113
|
-
|
|
114
|
-
const props = _objectSpread({
|
|
115
|
-
width: width || this.state.width || initialWidth || initialWidthOption || getThemeProps({
|
|
116
|
-
theme,
|
|
117
|
-
name: 'MuiWithWidth'
|
|
118
|
-
}).initialWidth
|
|
119
|
-
}, other);
|
|
120
|
-
|
|
121
|
-
const more = {};
|
|
122
|
-
|
|
123
|
-
if (withThemeOption) {
|
|
124
|
-
more.theme = theme;
|
|
125
|
-
} // When rendering the component on the server,
|
|
126
|
-
// we have no idea about the client browser screen width.
|
|
127
|
-
// In order to prevent blinks and help the reconciliation of the React tree
|
|
128
|
-
// we are not rendering the child component.
|
|
129
|
-
//
|
|
130
|
-
// An alternative is to use the `initialWidth` property.
|
|
131
|
-
|
|
132
|
-
|
|
133
|
-
if (props.width === undefined) {
|
|
134
|
-
return null;
|
|
135
|
-
}
|
|
136
|
-
|
|
137
|
-
return React.createElement(EventListener, {
|
|
138
|
-
target: "window",
|
|
139
|
-
onResize: this.handleResize
|
|
140
|
-
}, React.createElement(Component, _extends({}, more, props)));
|
|
141
|
-
}
|
|
142
|
-
|
|
143
|
-
}
|
|
144
|
-
|
|
145
|
-
WithWidth.propTypes = process.env.NODE_ENV !== "production" ? {
|
|
146
|
-
/**
|
|
147
|
-
* As `window.innerWidth` is unavailable on the server,
|
|
148
|
-
* we default to rendering an empty component during the first mount.
|
|
149
|
-
* In some situation, you might want to use an heuristic to approximate
|
|
150
|
-
* the screen width of the client browser screen width.
|
|
151
|
-
*
|
|
152
|
-
* For instance, you could be using the user-agent or the client-hints.
|
|
153
|
-
* http://caniuse.com/#search=client%20hint
|
|
154
|
-
*/
|
|
155
|
-
initialWidth: PropTypes.oneOf(['xs', 'sm', 'md', 'lg', 'xl']),
|
|
156
|
-
|
|
157
|
-
/**
|
|
158
|
-
* @ignore
|
|
159
|
-
*/
|
|
160
|
-
theme: PropTypes.object.isRequired,
|
|
161
|
-
|
|
162
|
-
/**
|
|
163
|
-
* Bypass the width calculation logic.
|
|
164
|
-
*/
|
|
165
|
-
width: PropTypes.oneOf(['xs', 'sm', 'md', 'lg', 'xl'])
|
|
166
|
-
} : {};
|
|
167
|
-
|
|
168
|
-
if (process.env.NODE_ENV !== 'production') {
|
|
169
|
-
WithWidth.displayName = wrapDisplayName(Component, 'WithWidth');
|
|
170
|
-
}
|
|
171
|
-
|
|
172
|
-
hoistNonReactStatics(WithWidth, Component);
|
|
173
|
-
return withTheme()(WithWidth);
|
|
174
|
-
};
|
|
175
|
-
|
|
176
|
-
export default withWidth;
|
package/withWidth/index.js
DELETED
|
@@ -1,27 +0,0 @@
|
|
|
1
|
-
"use strict";
|
|
2
|
-
|
|
3
|
-
var _interopRequireWildcard = require("@babel/runtime/helpers/interopRequireWildcard");
|
|
4
|
-
|
|
5
|
-
Object.defineProperty(exports, "__esModule", {
|
|
6
|
-
value: true
|
|
7
|
-
});
|
|
8
|
-
var _exportNames = {};
|
|
9
|
-
Object.defineProperty(exports, "default", {
|
|
10
|
-
enumerable: true,
|
|
11
|
-
get: function get() {
|
|
12
|
-
return _withWidth.default;
|
|
13
|
-
}
|
|
14
|
-
});
|
|
15
|
-
|
|
16
|
-
var _withWidth = _interopRequireWildcard(require("./withWidth"));
|
|
17
|
-
|
|
18
|
-
Object.keys(_withWidth).forEach(function (key) {
|
|
19
|
-
if (key === "default" || key === "__esModule") return;
|
|
20
|
-
if (Object.prototype.hasOwnProperty.call(_exportNames, key)) return;
|
|
21
|
-
Object.defineProperty(exports, key, {
|
|
22
|
-
enumerable: true,
|
|
23
|
-
get: function get() {
|
|
24
|
-
return _withWidth[key];
|
|
25
|
-
}
|
|
26
|
-
});
|
|
27
|
-
});
|