chore: bump superset-ui and update references to queriesData (#22)

* chore: update references to queriesData

* fix: add legacy time sections

* fix: add missing deps
This commit is contained in:
Ville Brofeldt 2020-12-29 22:00:30 +02:00 committed by Yongjie Zhao
parent 687b70d640
commit 9e10e04dbe
23 changed files with 3790 additions and 3969 deletions

View File

@ -48,8 +48,8 @@
"@airbnb/config-typescript": "^2.1.2",
"@airbnb/nimbus": "^2.1.3",
"@superset-ui/commit-config": "^0.0.9",
"@superset-ui/chart-controls": "^0.15.0",
"@superset-ui/core": "^0.15.0",
"@superset-ui/chart-controls": "^0.16.3",
"@superset-ui/core": "^0.16.3",
"@types/enzyme": "^3.10.5",
"@types/jest": "^25.1.1",
"@types/jsdom": "^12.2.4",

View File

@ -33,8 +33,8 @@ Then use it via `SuperChart`. See [storybook](https://apache-superset.github.io/
width={600}
height={600}
formData={...}
queryData={{
queriesData={[{
data: {...},
}}
}]}
/>
```

View File

@ -46,8 +46,8 @@
"xss": "^1.0.6"
},
"peerDependencies": {
"@superset-ui/chart-controls": "^0.15.0",
"@superset-ui/core": "^0.15.0",
"@superset-ui/chart-controls": "^0.16.3",
"@superset-ui/core": "^0.16.3",
"react": "^15 || ^16"
}
}

View File

@ -16,6 +16,7 @@
* specific language governing permissions and limitations
* under the License.
*/
import { sections } from '@superset-ui/chart-controls';
import { t, validateNonEmpty, legacyValidateInteger } from '@superset-ui/core';
import timeGrainSqlaAnimationOverrides, {
columnChoices,
@ -38,6 +39,7 @@ import {
export default {
controlPanelSections: [
sections.legacyRegularTime,
{
label: t('Query'),
expanded: true,

View File

@ -16,6 +16,7 @@
* specific language governing permissions and limitations
* under the License.
*/
import { sections } from '@superset-ui/chart-controls';
import { t, validateNonEmpty, legacyValidateInteger } from '@superset-ui/core';
import { formatSelectOptions } from '../../utilities/utils';
import { columnChoices } from '../../utilities/controls';
@ -36,6 +37,7 @@ import {
export default {
controlPanelSections: [
sections.legacyRegularTime,
{
label: t('Query'),
expanded: true,

View File

@ -16,6 +16,7 @@
* specific language governing permissions and limitations
* under the License.
*/
import { sections } from '@superset-ui/chart-controls';
import { t, validateNonEmpty } from '@superset-ui/core';
import {
filterNulls,
@ -33,6 +34,7 @@ import {
export default {
controlPanelSections: [
sections.legacyRegularTime,
{
label: t('Query'),
expanded: true,

View File

@ -16,6 +16,7 @@
* specific language governing permissions and limitations
* under the License.
*/
import { sections } from '@superset-ui/chart-controls';
import { t, validateNonEmpty, legacyValidateInteger } from '@superset-ui/core';
import { formatSelectOptions } from '../../utilities/utils';
import { columnChoices } from '../../utilities/controls';
@ -36,6 +37,7 @@ import {
export default {
controlPanelSections: [
sections.legacyRegularTime,
{
label: t('Query'),
expanded: true,

View File

@ -16,6 +16,7 @@
* specific language governing permissions and limitations
* under the License.
*/
import { sections } from '@superset-ui/chart-controls';
import { t } from '@superset-ui/core';
import {
filterNulls,
@ -34,6 +35,7 @@ import {
export default {
controlPanelSections: [
sections.legacyRegularTime,
{
label: t('Query'),
expanded: true,

View File

@ -16,6 +16,7 @@
* specific language governing permissions and limitations
* under the License.
*/
import { sections } from '@superset-ui/chart-controls';
import { t } from '@superset-ui/core';
import timeGrainSqlaAnimationOverrides from '../../utilities/controls';
import { formatSelectOptions } from '../../utilities/utils';
@ -45,6 +46,7 @@ import {
export default {
controlPanelSections: [
sections.legacyRegularTime,
{
label: t('Query'),
expanded: true,

View File

@ -16,6 +16,7 @@
* specific language governing permissions and limitations
* under the License.
*/
import { sections } from '@superset-ui/chart-controls';
import { t, validateNonEmpty } from '@superset-ui/core';
import timeGrainSqlaAnimationOverrides from '../../utilities/controls';
import {
@ -48,6 +49,7 @@ export default {
},
}),
controlPanelSections: [
sections.legacyRegularTime,
{
label: t('Query'),
expanded: true,

View File

@ -16,6 +16,7 @@
* specific language governing permissions and limitations
* under the License.
*/
import { sections } from '@superset-ui/chart-controls';
import { t, validateNonEmpty } from '@superset-ui/core';
import timeGrainSqlaAnimationOverrides from '../../utilities/controls';
import {
@ -33,6 +34,7 @@ import {
export default {
controlPanelSections: [
sections.legacyRegularTime,
{
label: t('Query'),
expanded: true,

View File

@ -19,14 +19,14 @@
const NOOP = () => {};
export default function transformProps(chartProps) {
const { width, height, rawFormData, queryData, hooks } = chartProps;
const { width, height, rawFormData, queriesData, hooks } = chartProps;
const { onAddFilter = NOOP, setControlValue = NOOP } = hooks;
return {
formData: rawFormData,
height,
onAddFilter,
payload: queryData,
payload: queriesData[0],
setControlValue,
viewport: {
...rawFormData.viewport,

View File

@ -37,8 +37,8 @@
"viewport-mercator-project": "^6.1.1"
},
"peerDependencies": {
"@superset-ui/chart-controls": "^0.15.0",
"@superset-ui/core": "^0.15.0",
"@superset-ui/chart-controls": "^0.16.3",
"@superset-ui/core": "^0.16.3",
"react": "^15 || ^16"
}
}

View File

@ -17,8 +17,8 @@
* under the License.
*/
export default function transformProps(chartProps) {
const { formData, height, width, queryData, hooks } = chartProps;
const { mapboxApiAccessToken, features } = queryData.data;
const { formData, height, width, queriesData, hooks } = chartProps;
const { mapboxApiAccessToken, features } = queriesData[0].data;
const { config, autozoom, readonly } = formData;
return {

View File

@ -41,6 +41,8 @@
"@types/storybook__react": "3.0.7",
"bootstrap": "^4.3.1",
"react": "^16.6.0",
"react-bootstrap": "^0.33.1",
"react-loadable": "^5.5.0",
"storybook-addon-jsx": "^7.1.0"
},
"devDependencies": {
@ -51,7 +53,7 @@
"terser-webpack-plugin": "^2.1.0"
},
"peerDependencies": {
"@superset-ui/chart-controls": "^0.15.0",
"@superset-ui/core": "^0.15.0"
"@superset-ui/chart-controls": "^0.16.3",
"@superset-ui/core": "^0.16.3"
}
}

View File

@ -13,7 +13,7 @@ export default [
width={400}
height={400}
datasource={dummyDatasource}
queryData={payload}
queriesData={[payload]}
formData={{
datasource: '10__table',
viz_type: 'deck_arc',

View File

@ -13,7 +13,7 @@ export default [
width={400}
height={400}
datasource={dummyDatasource}
queryData={payload}
queriesData={[payload]}
formData={{
datasource: '5__table',
viz_type: 'deck_grid',

View File

@ -13,7 +13,7 @@ export default [
width={400}
height={400}
datasource={dummyDatasource}
queryData={payload}
queriesData={[payload]}
formData={{
datasource: '5__table',
viz_type: 'deck_hex',

View File

@ -13,7 +13,7 @@ export default [
width={400}
height={400}
datasource={dummyDatasource}
queryData={payload}
queriesData={[payload]}
formData={{
datasource: '11__table',
viz_type: 'deck_path',

View File

@ -14,7 +14,7 @@ export default [
width={400}
height={400}
datasource={dummyDatasource}
queryData={payload}
queriesData={[payload]}
formData={{
datasource: '9__table',
viz_type: 'deck_polygon',
@ -80,7 +80,7 @@ export default [
width={400}
height={400}
datasource={dummyDatasource}
queryData={geojsonPayload}
queriesData={[geojsonPayload]}
formData={{
datasource: '9__table',
viz_type: 'deck_polygon',

View File

@ -13,7 +13,7 @@ export default [
width={400}
height={400}
datasource={dummyDatasource}
queryData={payload}
queriesData={[payload]}
formData={{
datasource: '5__table',
viz_type: 'deck_scatter',

View File

@ -13,7 +13,7 @@ export default [
width={400}
height={400}
datasource={dummyDatasource}
queryData={payload}
queriesData={[payload]}
formData={{
datasource: '5__table',
viz_type: 'deck_screengrid',