Skip to content

React 16.13 #92

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 10 commits into from
Mar 10, 2020
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
5 changes: 3 additions & 2 deletions .circleci/config.yml
Original file line number Diff line number Diff line change
Expand Up @@ -27,8 +27,9 @@ jobs:
command: |
python -m venv venv
. venv/bin/activate
pip install --upgrade pip
pip install dash[dev]>=1.6.1
git clone --depth 1 https://github.com/plotly/dash.git dash-main
cd dash-main && pip install -e .[dev,testing]
cd dash-renderer && npm run build && pip install -e . && cd ../..
npm run build

- run:
Expand Down
59 changes: 31 additions & 28 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -6,111 +6,114 @@ The format is based on [Keep a
Changelog](http://keepachangelog.com/en/1.0.0/) and this project
adheres to [Semantic Versioning](http://semver.org/spec/v2.0.0.html).

## [Unreleased]
- [#92](https://github.com/plotly/dash-daq/pull/92) Update from React 16.8.6 to 16.13.0

## [0.4.0] - 2020-03-04
### Added
* [#80](https://github.com/plotly/dash-daq/pull/80) Added `theme` prop to `GraduatedBar` component.
- [#80](https://github.com/plotly/dash-daq/pull/80) Added `theme` prop to `GraduatedBar` component.

### Changed
* [#91](https://github.com/plotly/dash-daq/pull/91) Renamed async modules with hyphen `-` instead of tilde `~`
* [#80](https://github.com/plotly/dash-daq/pull/80) Changed class names for components according to BEM conventions.
- [#91](https://github.com/plotly/dash-daq/pull/91) Renamed async modules with hyphen `-` instead of tilde `~`
- [#80](https://github.com/plotly/dash-daq/pull/80) Changed class names for components according to BEM conventions.

### Fixed
* [#80](https://github.com/plotly/dash-daq/pull/80) Fixed color problems for dark-theme buttons and inputs.
- [#80](https://github.com/plotly/dash-daq/pull/80) Fixed color problems for dark-theme buttons and inputs.

## [0.3.3] - 2020-01-23
### Changed
* [#82](https://github.com/plotly/dash-daq/pull/82) Updated `rc-slider` package and `daq.Slider` styling.
- [#82](https://github.com/plotly/dash-daq/pull/82) Updated `rc-slider` package and `daq.Slider` styling.

## [0.3.2] - 2020-01-22
### Fixed
* [#84](https://github.com/plotly/dash-daq/pull/84) Fixed JS map not being included in the `js_dist` for the Python package.
- [#84](https://github.com/plotly/dash-daq/pull/84) Fixed JS map not being included in the `js_dist` for the Python package.

## [0.3.1] - 2019-11-14
### Fixed
* [#73](https://github.com/plotly/dash-daq/pull/73) Fix IE11 compatibility issues and ES5 compatibility and validation
- [#73](https://github.com/plotly/dash-daq/pull/73) Fix IE11 compatibility issues and ES5 compatibility and validation

## [0.3.0] - 2019-11-05
### Added
* [#70](https://github.com/plotly/dash-daq/pull/70) Async ColorPicker and Slider components
- [#70](https://github.com/plotly/dash-daq/pull/70) Async ColorPicker and Slider components

## [0.2.2] - 2019-10-04

### Fixed
* Fixed ThemeProvider warning by updating `styled-components` to `v4.4.0`.
- Fixed ThemeProvider warning by updating `styled-components` to `v4.4.0`.

## [0.2.1] - 2019-09-24

### Fixed
* Fixed "Cannot read property 'subscribe' of undefined" JavaScript
- Fixed "Cannot read property 'subscribe' of undefined" JavaScript
error.

## [0.2.0] - 2019-09-24

### Added
* Added `height` and `width` parameters to `daq.Tank` and
- Added `height` and `width` parameters to `daq.Tank` and
`daq.Thermometer`.

## [0.1.7] - 2019-07-24

### Changed
* Updated library to React 16 for compatibility with `dash-1.0.0`.
- Updated library to React 16 for compatibility with `dash-1.0.0`.

## [0.1.6] - 2019-07-16

### Added
* Added ability for LEDDisplay to handle negative numbers.
- Added ability for LEDDisplay to handle negative numbers.

## [0.1.5] - 2019-05-09

### Fixed
* Fixed missing locationSlider entry in Slider.propTypes.
- Fixed missing locationSlider entry in Slider.propTypes.

### Added

* Updated package.json with additional metadata for R package
- Updated package.json with additional metadata for R package
building.
* Added JavaScript bundle and source map to dash_daq subfolder.
* Initial commit of dashDaq R package.
- Added JavaScript bundle and source map to dash_daq subfolder.
- Initial commit of dashDaq R package.

## [0.1.4] - 2019-02-18

### Fixed
* Fixed init file to include the correct bundle location.
* Fixed NPM package to include bundle, and updated Python package
- Fixed init file to include the correct bundle location.
- Fixed NPM package to include bundle, and updated Python package
version accordingly.

## [0.1.2] - 2019-02-15

### Fixed
* Fixed version to correspond to the correct/published npm version.
- Fixed version to correspond to the correct/published npm version.

## [0.1.1] - 2019-02-14

### Fixed
* Fixed version to correspond to the correct/published npm version.
- Fixed version to correspond to the correct/published npm version.

## [0.1.0] - 2019-01-28

### Fixed
* Fixed incompatibility issue with Dash `0.36.0`.
- Fixed incompatibility issue with Dash `0.36.0`.

### Removed
* Removed unused headers in CHANGELOG.
* Removed all mentioned of `fireEvent` and anything else that used
- Removed unused headers in CHANGELOG.
- Removed all mentioned of `fireEvent` and anything else that used
Dash events (which have been removed). The `n_clicks` and `value`
props should be used instead to determine when something has been
updated.

## [0.0.2] - 2018-06-04

### Fixed
* Error on Windows when generating tarball. Fixed dependency problems
- Error on Windows when generating tarball. Fixed dependency problems
with import dash_daq.

## [0.0.1] - 2018-05-28

### Fixed

* Display error on ColorPicker Light component fixed
* Gauge component error with default values fixed
* Knob component error with JavaScript split method fixed
- Display error on ColorPicker Light component fixed
- Gauge component error with default values fixed
- Knob component error with JavaScript split method fixed
2 changes: 1 addition & 1 deletion dash_daq/async-colorpicker.js

Large diffs are not rendered by default.

2 changes: 1 addition & 1 deletion dash_daq/async-colorpicker.js.map

Large diffs are not rendered by default.

2 changes: 1 addition & 1 deletion dash_daq/async-slider.js

Large diffs are not rendered by default.

6 changes: 3 additions & 3 deletions dash_daq/dash_daq.min.js

Large diffs are not rendered by default.

2 changes: 1 addition & 1 deletion dash_daq/dash_daq.min.js.map

Large diffs are not rendered by default.

6 changes: 3 additions & 3 deletions dash_daq/package-info.json
Original file line number Diff line number Diff line change
Expand Up @@ -51,9 +51,9 @@
"prop-types": "^15.5.9",
"ramda": "^0.25.0",
"rc-slider": "^9.1.0",
"react": "^16.8.6",
"react-color": "^2.14.1",
"react-dom": "^16.8.6",
"react": "16.13.0",
"react-color": "^2.18.0",
"react-dom": "16.13.0",
"react-numeric-input": "^2.2.3",
"styled-components": "^4.4.0",
"tinygradient": "^0.4.0",
Expand Down
46 changes: 29 additions & 17 deletions package-lock.json

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

10 changes: 5 additions & 5 deletions package.json
Original file line number Diff line number Diff line change
Expand Up @@ -21,7 +21,7 @@
"copy-lib": "copyfiles -u 1 lib/* dash_daq",
"dash-demo": "python demo.py",
"install-local": "pip install -e .",
"lint": "eslint --fix --ignore-path .eslintignore .",
"lint": "eslint --fix --ignore-path .eslintignore src/",
"start": "npm run build:dev",
"build:js": "webpack --mode production",
"build:js-dev": "webpack --mode development",
Expand All @@ -32,7 +32,7 @@
"postbuild": "es-check es5 dash_daq/*.js",
"build:dev": "npm run build:js-dev && npm run build:py",
"build-tarball": "npm run build && python setup.py sdist",
"test": "jest",
"test": "jest src/components/__tests__",
"test:frontend-cov": "jest --coverage --silent",
"test:watch": "jest --watch",
"uninstall-local": "pip uninstall dash_daq -y",
Expand All @@ -51,9 +51,9 @@
"prop-types": "^15.5.9",
"ramda": "^0.25.0",
"rc-slider": "^9.1.0",
"react": "^16.8.6",
"react-color": "^2.14.1",
"react-dom": "^16.8.6",
"react": "16.13.0",
"react-color": "^2.18.0",
"react-dom": "16.13.0",
"react-numeric-input": "^2.2.3",
"styled-components": "^4.4.0",
"tinygradient": "^0.4.0",
Expand Down
3 changes: 1 addition & 2 deletions src/components/NumericInput.react.js
Original file line number Diff line number Diff line change
@@ -1,13 +1,12 @@
import React, { Component } from 'react';
import PropTypes from 'prop-types';
import { withTheme } from 'styled-components';
import { default as Input } from 'react-numeric-input';

import LabelContainer from '../styled/shared/LabelContainer.styled';

import { light, colors } from '../styled/constants';

import { getClassName, getFilteredProps } from '../helpers/classNameGenerator';
import Input from './../helpers/NumericInput';

/**
* A numeric input component that can be
Expand Down
3 changes: 1 addition & 2 deletions src/components/PrecisionInput.react.js
Original file line number Diff line number Diff line change
@@ -1,14 +1,13 @@
import React, { Component } from 'react';
import PropTypes from 'prop-types';
import { withTheme } from 'styled-components';
import { default as Input } from 'react-numeric-input';

import { Container, Digit, ExponentialDigit } from '../styled/PrecisionInput.styled';
import LabelContainer from '../styled/shared/LabelContainer.styled';

import { light, colors } from '../styled/constants';

import { getClassName, getFilteredProps } from '../helpers/classNameGenerator';
import Input from './../helpers/NumericInput';

const defaultRootStyles = {
display: 'flex',
Expand Down
11 changes: 11 additions & 0 deletions src/helpers/NumericInput.js
Original file line number Diff line number Diff line change
@@ -0,0 +1,11 @@
import { default as Input } from 'react-numeric-input';

Input.prototype.UNSAFE_componentWillMount = Input.prototype.componentWillMount;
Input.prototype.UNSAFE_componentWillReceiveProps = Input.prototype.componentWillReceiveProps;
Input.prototype.UNSAFE_componentWillUpdate = Input.prototype.componentWillUpdate;

delete Input.prototype.componentWillMount;
delete Input.prototype.componentWillReceiveProps;
delete Input.prototype.componentWillUpdate;
Copy link
Contributor Author

@Marc-Andre-Rivet Marc-Andre-Rivet Mar 4, 2020

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This component is old and not maintained, this makes it work without warnings in React 16.12+


export default Input;