Commit Graph

168 Commits

Author SHA1 Message Date
Maxime Beauchemin
eac97ce9f2 [explore] proper filtering of NULLs and '' (#4651)
* [WiP] [explore] proper filtering of NULLs and ''

TODO: handling of Druid equivalents

* Unit tests

* Some refactoring

* [druid] fix 'Unorderable types' when col has nuls

Error "unorderable types: str() < int()" occurs when grouping by a
numerical Druid colummn that contains null values.

* druid/pydruid returns strings in the datafram with NAs for nulls
* Superset has custom logic around get_fillna_for_col that fills in the
NULLs based on declared column type (FLOAT here), so now we have a mixed
bag of type in the series
* pandas chokes on pivot_table or groupby operations as it cannot sorts
mixed types

The approach here is to stringify and fillna('<NULL>') to get a
consistent series.

* typo

* Fix druid_func tests

* Addressing more comments

* last touches
2018-04-17 22:26:21 -07:00
Maxime Beauchemin
c0db6dbb57 Moving some JS folders (#4820)
* Moving folders

* Pointing to new locations
2018-04-17 21:05:01 -07:00
Maxime Beauchemin
6fd4ff45ea Improve the calendar heatmap (#4800)
* Improve xAxis ticks, thinner bottom margin (#4756)

* Improve xAxis ticks, thinner bottom margin

* Moving utils folder

* Add isTruthy

* Addressing comments

* Set cell_padding to 0

* merging db migrations
2018-04-12 17:16:45 -07:00
Beto Dealmeida
426c34ee86 Pass granularity from backend to frontend as ISO duration (#4755)
* Add ISO duration to time grains

* Use ISO duration

* Remove debugging code

* Add module to yarn.lock

* Remove autolint

* Druid granularity as ISO

* Remove dangling comma
2018-04-06 16:19:17 -07:00
Maxime Beauchemin
68999b1407 [deck_multi] fixing issues with deck_multi (#4754)
* [deck_multi] fixing issues with deck_multi

* removing eslint comment
2018-04-04 16:52:14 -07:00
Maxime Beauchemin
969ff0ce39 Fix deep equality logic (#4730)
* Fix deepequality logic

Zeroed-in on this while a Deck Scatter Plot chart was prompting for
refresh on-load.

I'm pretty sure using JSON.stringify as a proxy for deep equality is
wrong.

Not sure how to handle yarn.lock changes here. The changes on yarn.lock
are the result of "only" running `yarn add deep-equal`

* Adressing comments
2018-04-02 20:54:57 -07:00
Gabe Lyons
68dec24542 [Explore] Streamlined metric definitions for SQLA and Druid (#4663)
* adding streamlined metric editing

* addressing lint issues on new metrics control

* enabling druid
2018-03-28 17:41:29 -07:00
Beto Dealmeida
7089344623 Legend for deck.gl scatterplot (#4572)
* Initial work

* Working version

* Specify legend position

* Max height with scroll

* Fix lint

* Better compatibility with nvd3

* Fix object.keys polyfill version

* Fix lint
2018-03-14 16:40:14 -07:00
oxydash
8951990d6e [BugFix] Resizing widgets problem #4596 (#4597) 2018-03-12 14:27:02 -07:00
John Bodley
3fbadd68a4 [code-climate] Deprecating Code Climate from JavaScript tests 2018-03-08 22:40:08 -08:00
Maxime Beauchemin
d4a2f4ef36 Make npm run dev-fast the default (#4454) 2018-02-20 17:07:33 -08:00
Beto Dealmeida
4ee0833b27 Play scrubber (#4336)
* Initial working prototype

* Small fixes

* Refactoring dekgl

* Show all data when no time grain is selected

* Refactor layers

* Standardize function name

* Fix exports

* Fix require

* Initial working prototype

* Small fixes

* Show all data when no time grain is selected

* Moving play bar to correct location

* Split component

* Working on CSS

* Remove control

* Positioning the play slider

* Fix refresh of slider state

* Fix lint

* Small fixes

* Smoother animation for scans

* Fix versions

* Play/pause with spacebar.

* Small fixes

* Clean stuff that went to other PRs

* Address issues

* Refactor scatter animation
2018-02-15 17:55:11 -08:00
Riccardo Magliocchetti
22d555b14e Bump dependencies with security issues (#4427)
* assets: bump mathjs to 3.20.2

* assets: bump moment to 2.20.1
2018-02-14 09:44:44 -08:00
Maxime Beauchemin
e0bbb0c77e [geo] introduce "Auto Zoom" control (#4389)
* [geo] introduce "Auto Zoom" control

On geospatial visualization, checking the "Auto Zoom" control makes it
such that the viewport is fitted to the data upon rendering the chart.

For dashboards with region filters, the map should jump to the right
position.

Eventually we should enhance this to fly and ease to the position in an
animated way.

* Added TODO notes
2018-02-13 11:10:15 -08:00
Maxime Beauchemin
2e172d77cf Fix caching issues (#4316) 2018-02-07 14:49:19 -08:00
Maxime Beauchemin
01043c9bf4 Improve deck.gl GeoJSON visualization (#4220)
* Improve geoJSON

* Addressing comments

* lint
2018-01-17 14:01:32 -08:00
Maxime Beauchemin
87c3e831a8 Using user-defined Javascript to customize geospatial visualization (#4173)
* Using JS to customize spatial viz and tooltips

* Add missing deck_multi.png

* Improve GeoJSON layer with JS support and extra controls

* Addressing comments
2018-01-11 15:42:44 -08:00
fabianmenges
500e6256c0 Full Annotation Framework (#3518)
* Adding full Annotation Framework

* Viz types

* Re organizing native annotations

* liniting

* Bug fix

* Handle no data

* Cleanup

* Refactor slice form_data to data
2017-12-16 16:10:45 -08:00
Maxime Beauchemin
6188d60fec Bump dev version on trunk (#4048) 2017-12-12 21:29:19 -08:00
Maxime Beauchemin
0b40c8a26f Add fastdom js dependency (#3947)
The nvd3 docs say that it if the fastdom library is present it makes use
of it.

"Including Fastdom in your project can greatly increase the performance
of the line chart (particularly in Firefox and Internet Explorer) by
batching DOM read and write operations to avoid layout thrashing. NVD3
will take advantage of Fastdom if present."
2017-12-07 16:36:46 -08:00
Chris Williams
76a2f95231 [time series table] visual improvements (#3957)
* [time series table] visual improvements

* [time series table] don't set cell color if text color isn't set
2017-11-30 20:48:17 -08:00
Maxime Beauchemin
d9fda346cb Add an "Edit Mode" to Dashboard view (#3940)
* Add a togglable edit mode to dashboard

* Submenu for controls

* Allowing 'Save as' outside of editMode

* Set editMode to false as default
2017-11-28 09:10:21 -08:00
Maxime Beauchemin
b82d15af76 Bumping webpack related deps (#3904) 2017-11-20 15:27:02 -08:00
Maxime Beauchemin
3a8af5d0b0 DECKGL integration - Phase 1 (#3771)
* DECKGL integration

Adding a new set of geospatial visualizations building on top of the
awesome deck.gl library. https://github.com/uber/deck.gl

While the end goal it to expose all types of layers and let users bind
their data to control most props exposed by the deck.gl API, this
PR focusses on a first set of visualizations and props:

* ScatterLayer
* HexagonLayer
* GridLayer
* ScreenGridLayer

* Addressing comments

* lint

* Linting

* Addressing chri's comments
2017-11-16 00:30:02 -08:00
Jeff Niu
4d48d5d854 [Explore] Altered Slice Tag (#3668)
* Added altered tag to explore slice view and fixes #3616

* unit tests

* Moved getDiffs logic into AlteredSliceTag

* code style fixs
2017-11-10 21:33:31 -08:00
Maxime Beauchemin
39e502faae Stamping version to 0.21.0dev (#3801)
Making it clear that master has a `dev`-suffixed version. Proper release
number will be created in release branches.

There are constraints as to what npm and setuptools will accept as a
proper version number and N.N.Ndev seems to work so I'm rolling with it

Open to suggestion as to how to tag `master`
2017-11-08 09:47:41 -08:00
Chris Williams
7f3edad119 [time table] add tooltip to sparkline (#3767)
* [time table] add tooltip to sparkline

* [time table] open link in new tab

* [time table] add back Mustache
2017-11-03 12:37:15 -07:00
Maxime Beauchemin
abfa03474c Bumping react-select to rc10 (#3726) 2017-10-31 22:03:18 -07:00
Grace Guo
cbd01074ba bump react-bootstrap version (#3723)
1. avoid exports is not defined error
2. per jordan's suggestion, update .babelrc only use airbnb presets
2017-10-26 23:10:00 -07:00
Jay Lindquist
b4bdc45a6b Add support for IE 11 for markup slices (#3702)
* Add srcdoc-polyfill tosupport Internet Explorer iframes in markup slices. Add allow-top-navigation and allow-popups to support links within iframes

* Remove jquery from markup.js
2017-10-23 15:35:15 -07:00
Maxime Beauchemin
d0b5b449b2 Add a ColorPickerControl (#3653)
* Add a ColorPickerControl

* Tests
2017-10-15 23:38:38 -07:00
Jeff Niu
bad6938d1a [New Viz] Partition Diagram (#3642)
* Added Partition Visualization

* added unit tests
2017-10-12 21:54:59 -07:00
Maxime Beauchemin
6cc6637454 Pin moment.js library since 2.19.0 creates problem (#3641)
The 2.19.0 released today (2017-10-10) creates issues with the
DateFilterControl somehow. Pining lib to latest known version.
2017-10-10 15:53:03 -07:00
Maxime Beauchemin
1fb8716231 [hotfix] fixing issues around new time_table viz (#3599) 2017-10-04 16:22:11 -07:00
Denny Biasiolli
ff268a7526 updating react-alert dependency to v2.3.0 (#3596)
it was downgraded in commit 7045018d86.
The old version used React.PropTypes and it was deprecated.
This version is compatible with React 15+.

Fix #3588
2017-10-04 12:08:06 -07:00
Maxime Beauchemin
bb0f69d074 New "Time Series - Table" visualization (#3543)
* [WiP] adding a new "Time Series - Table" viz

* Adding drag-n-drop to collection

* Using keys in arrays

* tests
2017-10-04 10:17:33 -07:00
Naoya Kanai
04ea3addc4 update immutable.js to v3.8.2 (MIT license) (#3591) 2017-10-04 09:07:12 -07:00
Maxime Beauchemin
fdbc936dc9 Bumping React to 15.6.2 (MIT license) (#3569)
I think that leaves only immutable.js with the ASF-incompatible PATENTS clause

I asked for a 3.8.x MIT release of the immutable lib here:
https://github.com/facebook/immutable-js/issues/1309
2017-10-03 15:57:42 -07:00
Maxime Beauchemin
18e459e19e v0.20.1 (#3576) 2017-10-03 00:04:43 -07:00
Denny Biasiolli
9baca6758d Removing yarn warnings during install (#3567)
* removing deprecated babel-preset-es2015 in favor of babel-preset-env

This removes this yarn warning during install:

```
warning babel-preset-es2015@6.24.1:
Thanks for using Babel: we recommend using babel-preset-env now:
please read babeljs.io/env to update!
```

* updating sinon to 4.0.0

This removes wrench from its dependencies and this yarn warning during install:

```
warning wrench@1.3.9: wrench.js is deprecated!
You should check out fs-extra (https://github.com/jprichardson/node-fs-extra)
for any operations you were using wrench for.
Thanks for all the usage over the years.
```
2017-10-02 15:25:37 -07:00
Maxime Beauchemin
b50489eb96 v0.20.0 (#3544) 2017-09-27 20:38:50 -07:00
Jeff Niu
c629282ec4 Feature: Paired t-test table visualization (#3473)
* Feature: paired t-test table viz

* Added unit tests for viz
2017-09-26 15:11:35 -07:00
Grace Guo
9af34ba51c js translation -- performance improvment (#3390)
* Chinese page

* Using react-intl-universal to improve multi language in react page

* Using react-intl-universal to improve multi language in react page

* react_intl_universal

* change

* change

* change

* change

* change

* change

* change

* merge

* multiple page in js

* merge

* merge

* merge

* merge

* Js Translations

* JS Translation

* JS Translations

* Js translation

* JS translations

* JS translations

* Js translaion

* JS en Translation

* JS Translation

* upgrade document

Fixing the damn build (#3179)

* Fixing the build

* Going deeper

[bugfix] only filterable columns should show up in FilterBox list (#3105)

* [bugfix] only filterable columns should show up in FilterBox list

* Touchups

Datasource cannot be empty (#3035)

add title description to model view (#3045)

* add title description to model view

* add missing import

Add 'show/hide totals' option to pivot table vis (#3101)

[bugfix] numeric value for date fields in table viz (#3036)

Bug was present only when using the NOT GROUPED BY option

fixes https://github.com/ApacheInfra/superset/issues/3027

fix hive.fetch_logs (#2968)

add Zalando to the list of organizations (#3171)

docs: fixup installation examples code indentation (#3169)

[bugfix] fix bar order (#3180)

[bugfix] visualize flow error: 'Metric x is not valid' (#3181)

The metric name in the frontend doesn't match the one generated on the
backend. It turns out the explore view will default to the first
metric so specifying one isn't needed.

Fix the segment interval for pulling metadata (#3174)

The end of the interval would be on the truncated today date, which
means that you will exclude today. If your realtime ingestion job
runs shorter than a day, the metadata cannot be pulled from the
druid cluster.

Bump cryptography to 1.9 (#3065)

As 1.7.2 doesn't compile here with openssl 1.1.0f

Escaping the user's SQL in the explore view (#3186)

* Escaping the user's SQL in the explore view

When executing SQL from SQL Lab, we use a lower level API to the
database which doesn't require escaping the SQL. When going through
the explore view, the stack chain leading to the same method may need
escaping depending on how the DBAPI driver is written, and that is the
case for Presto (and perhaps other drivers).

* Using regex to avoid doubling doubles

[sqllab] improve Hive support (#3187)

* [sqllab] improve Hive support

* Fix "Transport not open" bug
* Getting progress bar to show
* Bump pyhive to 0.4.0
* Getting [Track Job] button to show

* Fix testzz

Add BigQuery engine specifications (#3193)

As contributed by @mxmzdlv on issue #945

[bugfix] fix merge conflict that broke Hive support (#3196)

Adding 'apache' to docs (#3194)

[druid] Allow custom druid postaggregators (#3146)

* [druid] Allow custom druid postaggregators

Also, fix the postaggregation for approxHistogram quantiles so it adds
the dependent field and that can show up in the graphs/tables.

In general, postAggregators add significant power, we should probably
support including custom postAggregators. Plywood has standard
postAggregators here, and a customAggregator escape hatch that allows
you to define custom postAggregators.

This commit adds a similar capability for Superset and a additional
field/fields/fieldName breakdown of the typical naming for dependent
aggregations, which should make it significantly easier to develop
approxHistogram and custom postAggregation-required dashboards.

* [druid] Minor style cleanup in tests file.

* [druid] Apply code review suggestions

* break out CustomPostAggregator into separate class. This just cleans
  up the creation of the postaggregator a little bit.
* minor style issues.
* move the function around so the git diff is more readable

add combine config for metrics in pivot table (#3086)

* add combine config for metrics in pivot table

* change method to stack/unstack

* update backendSync

Autofocus search input in VizTypeControl modal onEnter (#2929)

Speed up JS build time (#3203)

Also bumping a few related libs

JS Translation

JS translations

js translation

fix issue 3204 (#3205)

[bugfix] capture Hive job_id pre-url transformation (#3213)

js translation

fix issue 3204 (#3205)

[bugfix] capture Hive job_id pre-url transformation (#3213)

[docs] update url in CONTRIBUTING.md (#3212)

[sqllab/cosmetics] add margin-top for labels in query history (#3222)

[explore] nvd3 sort values in rich tooltip (#3197)

[sqllab] fix UI shows 'The query returned no results' momentarily (#3214)

this is visible when running async queries between the fetching and
success state as the rows are getting cached in the component

[explore] DatasourceControl to pick datasource in modal (#3210)

* [explore] DatasourceControl to pick datasource in modal

Makes it easier to change datasource, also makes it such that the list
of all datasources doesn't need to be loaded upfront.

* Adding more metadata

* Js translation

* js tran

* js trans

* js trans

* js tran

* js trans

* js trans

* js tran

* js translation

* js trans

* js translation

* try load language pack async

* Backend translations things

* create language pack inside common data

* performance improvement for js i18n.

- js bundle should not contain localized content
- we populate translation content from server-side, in boostrap.common.language_pack
- in client-side, use promise to wrap around translation content. text will be translated after translation content arrived/parsed.
- fix linting

* fix Timer unit test

* 1. add global hook for all tests, to make translation pack avaialble before each test starts.
2. fix unit test for Timer component
3. remove noused method get_locale, and modules
4. fix page reload after user change page language

* parse and build i18n dictionary as a module

* fix sync-backend task, which should run without DOM
2017-09-20 12:37:33 -07:00
Maxime Beauchemin
49f24d128b [heatmap] numerous improvements (#3456)
* [heatmap] numerous improvements

* flexibility as to how to sort X and Y axis (alpha/value, desc/asc)
* option to show a legend
* fixed margins, maximize real estate
* allowed users to define bounds

* Tunning
2017-09-13 16:13:45 -07:00
Maxime Beauchemin
147c12dddf Fixing the build (#3445)
* Bumping npm

* Fixing the build

This addresses long standing issues and hacks around react-map-gl
that have been creating all sorts of build issues over time.

It appears that recent changes broke things further.

This PR upgrades to the latest `react-map-gl` and removes related hacks.
2017-09-11 16:30:39 -07:00
Maxime Beauchemin
a782d623f0 Build optimizations (#3378)
Bumping some version, removing unused libs, ...
2017-08-28 16:16:52 -07:00
Maxime Beauchemin
48b88e5241 [dashboard] load list of slices at modal enter time (#3379) 2017-08-28 14:31:43 -07:00
Maxime Beauchemin
a47a512808 [explore] Improved time filters controls (#3371)
* Improved time filters controls

* lint

* Fix coverage

* Allow empty dates
2017-08-28 09:16:23 -07:00
Maxime Beauchemin
aff7a82664 [sql lab] using react-split-pane (#3363)
* [sql lab] using react-split-pane

* padding
2017-08-27 15:01:24 -07:00
Maxime Beauchemin
2d237fe2ef v1.9.1 (#3376) 2017-08-26 15:07:17 -07:00