Commit Graph

388 Commits

Author SHA1 Message Date
Kamil Gabryjelski ff5b4bc0e4
feat: Reuse Dashboard redux data in Explore (#20668) 2022-07-12 19:17:25 +02:00
Yongjie Zhao 8d4994a899
fix: superset-ui/core code coverage (#20676) 2022-07-12 13:34:27 +08:00
Yongjie Zhao 7f918a4ec0
fix: annotation broken (#20651)
* fix: annotation broken

* fix UT

* add annotation data to mixed timeseries chart
2022-07-11 16:23:57 -06:00
Diego Medina c29261b63d
fix: X Axis should be called Y Axis when using the Bar Chart V2 on Horizontal mode (#20659) 2022-07-09 12:36:16 +08:00
Jack Fragassi dfab521f50
fix(embedded): Ensure guest token is passed to log endpoint (#20647)
* Pass guest token to sendBeacon

* Add tests
2022-07-08 15:17:01 -07:00
AAfghahi 0ce0c6e1eb
chore: removing Druid from front- and back- end (#20338)
* first pass at removing native Druid nosql

* removing having_druid

* addressing comments, linting

* fixed all tests

* addressing comments

* redirected to ui-core TimeGranularity type

* query form metric linting

* fixed broken chart type

* implementing feedback
2022-07-08 17:57:03 +02:00
Kamil Gabryjelski de4f7db57e
feat(dashboard): Transition to Explore with React Router (#20606)
* feat(dashboard): Use react-router for transition to Explore + cmd click to open in new tab

* Update tooltip

* Add a feature flag

* Update edit chart onclick event

* Fix lint

* Fix tests

* Change feature flag name

* Add tooltip to Edit chart
2022-07-07 11:52:03 +02:00
stevetracvc 7e504ff680
feat: truncate long values in table viz, a per-column setting (#19383)
* feat: truncate long values, a per-column setting

* fix: lint

* fix: removed width for column control

* fix: removed truncate option for time, bool, and numeric columns

* prevent extra div if not truncating
2022-07-06 22:16:48 -06:00
David Aaron Suddjian db088e9e2f
chore: rename "uiOverrideRegistry" -> "extensionsRegistry" (#20628)
* uiOverrideRegistry -> extensionsRegistry

* better comments

* missed a spot

* missed another spot

* url
2022-07-06 11:35:19 -07:00
Yongjie Zhao 59491f5396
chore: rename drop missing columns to show empty columns (#20602) 2022-07-05 16:09:16 +08:00
Yongjie Zhao 309327dcbd
feat: drop missing columns control (#20586) 2022-07-04 18:08:12 +08:00
Lily Kuang 2389871556
feat: add extension point to the top of welcome page (#20575)
* welcome top extension

* show database modal

* add test

* Delete lines.svg

* rename to banner

* remove lines

Co-authored-by: David Aaron Suddjian <1858430+suddjian@users.noreply.github.com>
2022-07-01 12:21:13 -07:00
Yongjie Zhao b870a21eaa
refactor: remove unused flatten function (#20582) 2022-07-01 19:17:55 +08:00
Evan Rusackas ac8e502228
fix: Respecting max/min opacities, and adding tests. (#20555)
* Respecting max/min opacities, and adding tests.

* revising tests

* Adding missing test case for maximum coverage :)

* removing unnecessary logic and test

* adding another unit test for (hopefully) full coverage.

* no more ternary operator

* New approach with Math.min  - take THAT codecov.

* one more stab at making codecov happy... ignoring the file next.

* lint fixes
2022-06-30 16:09:03 -06:00
Kamil Gabryjelski b30f6a5db1
chore(explore): Get Explore data from endpoint instead of bootstrap_data (#20519)
* feat(explore): Use v1/explore endpoint data instead of bootstrapData

* Add tests

* Fix ci

* Remove redundant dependency

* Use form_data_key in cypress tests

* Add auth headers to for data request

* Address comments

* Remove displaying danger toast

* Conditionally add auth headers

* Address comments

* Fix typing bug

* fix

* Fix opening dataset

* Fix sqllab chart create

* Run queries in parallel

* Fix dashboard id autofill

* Fix lint

* Fix test
2022-06-30 21:06:51 +02:00
Sam Faber-Manning f2af81b1c7
feat: add extension point to the right side of the menu bar (#20514)
* add setupExtensions

* add 'navbar.right' extension to registry

* add test for navbar.right extension point

* rename MenuRight -> RightMenu

* lint
2022-06-30 11:43:20 -06:00
Yongjie Zhao 927d066f70
chore: move isAdhocColumn from controls to core (#20529)
* chore: move isAdhocColumn to superset-ui/core

* ut
2022-06-29 13:09:44 +08:00
Kamil Gabryjelski e12ee59b13
feat(explore): Apply denormalization to tier 2 charts form data (#20524)
* feat(explore): Denormalize form data in Calendar Heatmap

* feat(explore): Denormalize form data in Bubble

* feat(explore): Denormalize form data in Chord

* Dimensions -> Dimension for single selection

* feat(explore): Denormalize form data in Country Map

* feat(explore): Denormalize form data in Heatmap

* feat(explore): Denormalize form data in Histogram

* feat(explore): Denormalize form data in Handlebars

* feat(explore): Denormalize form data in Percent Change

* Use new standardized form data interface
2022-06-28 20:21:36 +02:00
Yongjie Zhao c348a095b9
refactor(standardized form data): refine interface and improve code smells (#20518) 2022-06-28 21:09:42 +08:00
Yongjie Zhao bbbe102887
feat(standardized form data): keep all columns and metrics (#20377) 2022-06-24 21:46:25 +08:00
Kamil Gabryjelski c7f1c7d5bd
chore: Restructure explore redux state (#20448)
* chore: Restructure explore redux state

* fixes

* fix tests

* add new tests

* Fix type

* Address comments

* Fix bug

* Fix import

* Add new test

* Move unsaved chart id to a constant

* Add todo
2022-06-24 15:26:07 +02:00
Eric Briscoe 9f9aae49c9
chore: Convert QueryAutoRefresh to TypeScript functional React component [sc-48362] (#20179)
* git commit -m 'Convert QueryAutoRefresh to functional component [sc-48362]'

* addressing PR comments [sc-48362]

Removes unneeded props and state tracking of offline, adds finally block to simplify clearing pending request, simplifies value comparison in array by using includes in place of indexOf

* Address PR comment to use enum for QueryState [sc-48362]

Original implementation had string literals used in multiple places representing Query.state value options.  This commit creates a formal TypeScript enum for QueryState so we can remove string literals and ensure better consistency

* Address PR comments for object type validation [sc-48362]

This commit resolves an issue why the TypeScript typing for queryList was marked as a Query[] but was actually a Dictionary (associative array) or Queries.  A new type QueryDictionary has been added and the QueryAutoRefresh code was adjusted to use QueryDictionary instead of Query[] in appropriate places as well as unit tests.  Commit also removes QueryAutoRefreshContainer by making the once component using QueryAutoRefresh (which is already redux connected) pass the needed values on props.  this simplifies the code base and reduce files that need unit testing while keeping QueryAutoRefresh out of needing a redux connection directly.

* Addresses PR comment to add QueryState.SCHEDULED to runningQueryStateList [sc-48362]

In previous implementation 'scheduled' was not included int he list of Query States.  Further investigation shows it should be added to as a running state.

* Fix prettier lint error [sc-48362]

* Adjust unit tests for props update hoisting callbacks out of actions wrapper object [sc-48362]

* Update with changes from master [sc-48362]

Merges in updates from master and resolves conflicts from relocation of some of the Query TypeScript definitions into core

* Removes logic setting user offline and relying on results panel error message [sc-48362]

* Fixes bad import after some TypeScript definitions were relocated to core [sc-48362]

* Fixes TypeScript errors [sc-48362]
2022-06-22 13:20:02 -07:00
Yongjie Zhao 9fad26fa19
fix: suppress translation warning in jest (#20404) 2022-06-21 20:38:58 +08:00
Yongjie Zhao c79b0d62d0
refactor: create echarts query section (#20445) 2022-06-21 11:38:07 +08:00
Sam Firke b7eb235440
style(typo): occured -> occurred (#20116)
* Occured -> Occurred

* Occured -> Occurred

* Occured -> Occurred

* Occured - > Occurred

* Update FallbackComponent.tsx

* Update FallbackComponent.tsx

Co-authored-by: John Bodley <4567245+john-bodley@users.noreply.github.com>
2022-06-20 08:49:45 -07:00
Yongjie Zhao 111affdb02
chore: move xaxis to superset-ui (#20438) 2022-06-20 22:36:27 +08:00
Lily Kuang ab9f72f1a1
fix(embedded): CSV download for chart (#20261)
* move postForm to superset client

* lint

* fix lint

* fix type

* update tests

* add tests

* add test for form submit

* add test for request form

* lint

* fix test

* fix tests

* more tests

* more tests

* test

* lint

* more test for postForm

* lint

* Update superset-frontend/packages/superset-ui-core/test/connection/SupersetClientClass.test.ts

Co-authored-by: David Aaron Suddjian <1858430+suddjian@users.noreply.github.com>

* update tests

* remove useless test

* make test cover happy

* make test cover happy

* make test cover happy

* make codecov happy

* make codecov happy

Co-authored-by: David Aaron Suddjian <1858430+suddjian@users.noreply.github.com>
2022-06-17 20:01:08 -07:00
Stephen Liu 1665403484
fix(plugin-chart-pivot-table): color weight of Conditional formatting metrics not work (#20396)
* fix(plugin-chart-pivot-table): color weight of Conditional formatting metrics not work

* fix: test
2022-06-16 12:22:09 +08:00
Michael S. Molina d6f9fb5af1
chore: Removes unused vars (#20194)
* chore: Removes unused vars

* Fixes lint

* Disables no-unused-vars for the operators
2022-06-15 11:01:45 -03:00
Yongjie Zhao 7c252d7524
feat: adding truncate metric control on timeseries charts (#20373) 2022-06-15 20:55:10 +08:00
Michael S. Molina cb2ffa530f
chore: Removes no-use-before-define warnings (#20298) 2022-06-13 07:44:34 -03:00
Yongjie Zhao d04357c47b
fix: superset-ui/core codes coverage (#20324) 2022-06-09 17:43:42 +08:00
Stephen Liu eab0009101
feat(plugin-chart-echarts): [feature-parity] support extra control for the area chart V2 (#16493)
* feat(echarts): [feature-parity] support extra control

* add extra control for plugin

* refactor: extract ExtraControl

* fix: lint

* fix some problems
2022-06-09 00:59:10 +08:00
Stephen Liu 9f02ff656d
fix(plugin-chart-echarts): [feature-parity] apply button of annotation layer doesn't work as expected (#19761)
* fix(plugin-chart-echarts): [feature-parity] apply button of annotation layer does't work

* fix: lint

* fix: test
2022-06-08 17:06:24 +08:00
Yongjie Zhao 8e46ae5c6a
chore: superset-ui/core code coverage (#20304) 2022-06-08 16:54:30 +08:00
Lyndsi Kay Williams ba0c37d3df
feat(explore): Frontend implementation of dataset creation from infobox (#19855)
* Frontend implementation of create dataset from infobox

* Fixed sl_dataset type

* Fix test

* Fixed sl_dataset type (forgot to save)

* RTL testing

* Adjusted styling/text on infobox and save dataset modal

* Appease lint

* Make infobox invisible and fix tests

* Remove unnecessary placeholder

* Move types to sql lab

* Moved logic into save dataset modal

* Change DatasourceMeta type to Dataset

* Add ExploreDatasource union type to save dataset modal

* Get user info from redux inside save dataset modal

* Addressed comments

* Adjusting to new query type

* Fixed save dataset in explore and union type

* Added testing

* Defined d for queries

* Remove dataset from SaveDatasetModal

* Clarify useSelector parameter

* Fix dndControls union type

* Fix shared-controls union type

* Fix controlPanel union type

* Move ExploreRootState to explore type file

* Remove unnecessary testing playground

* Move datasource type check in DatasourcePanel to a function

* Make all sqllab Query imports reference @superset-ui/core Query type

* Deconstruct query props in ResultSet

* Fix union type in /legacy-plugin-chart-heatmap/src/controlPanel

* Change SaveDatasetModal tests to RTL

* Cleaned datasourceTypeCheck

* Fix infobox styling

* Fix SaveDatasetModal test

* Fix query fixture in sqllab and Query type in SaveDatasetModal test

* Fix Query type and make test query fixture

* Added columns to Query type, separated results property, created QueryResponse union type, and fixed all types affected

* Fixed a couple missed broken types

* Added ExploreDatasource to SqlLab type file

* Removed unneeded Query import from DatasourcePanel

* Address PR comments

* Fix columnChoices

* Fix all incorrect column property checks

* Fix logic on dndGroupByControl

* Dry up savedMetrics type check

* Fixed TIME_COLUMN_OPTION

* Dried savedMetrics type check even further

* Change savedMetricsTypeCheck to defineSavedMetrics

* Change datasourceTypeCheck to isValidDatasourceType

* Fix Query path in groupByControl

* dnd_granularity_sqla now sorts Query types with is_dttm at the top

* Fixed/cleaned query sort

* Add sortedQueryColumns and proper optional chaining to granularity_sqla

* Move testQuery to core-ui, add test coverage for Queries in columnChoices

* Moved DEFAULT_METRICS to core-ui and wrote a test for defineSavedMetrics

* Add license and clean dataset test object

* Change DatasourceType.Dataset to dataset
2022-06-07 15:03:45 -05:00
Stephen Liu 5425504231
fix(codecov): improve core code coverage (#20274) 2022-06-06 17:21:23 +08:00
Yongjie Zhao 7faf874c1b
feat: derived metrics use different line style (#20242) 2022-06-05 21:17:31 +08:00
Yongjie Zhao dd4b581fb5
feat: standardized form_data (#20010) 2022-06-05 21:05:01 +08:00
Stephen Liu 80b5578680
feat(superset-ui-core): add feature flag for the analogous colors (#19987)
* feat(superset-ui-core): add feature flag for the color analogous generator

* fix: test
2022-06-03 21:32:32 +08:00
Stephen Liu 766f737728
feat(world-map): support color by metric or country column (#19881)
* feat(world-map): support color by metric or country column

* fix lint

* Update superset-frontend/packages/superset-ui-chart-controls/src/shared-controls/components/RadioButtonControl.tsx

Co-authored-by: Evan Rusackas <evan@preset.io>

* Update superset-frontend/plugins/legacy-plugin-chart-world-map/src/controlPanel.ts

Co-authored-by: Evan Rusackas <evan@preset.io>

* Update superset-frontend/plugins/legacy-plugin-chart-world-map/src/controlPanel.ts

Co-authored-by: Evan Rusackas <evan@preset.io>

* fix lint

Co-authored-by: Evan Rusackas <evan@preset.io>
2022-06-03 21:31:22 +08:00
Diego Medina 365acee663
fix: avoid while cycle in computeMaxFontSize for big Number run forever when css rule applied (#20173) 2022-05-25 18:04:04 +08:00
stevetracvc 7e9b85f76c
feat: add drag and drop column rearrangement for table viz (#19381) 2022-05-24 19:10:57 -07:00
Yongjie Zhao d7e3ac306f
chore: filter undefined operators (#20157) 2022-05-23 18:24:32 +08:00
Ville Brofeldt d5c5e58583
feat(plugin-chart-echarts): add support for generic axis to mixed chart (#20097)
* feat(plugin-chart-echarts): add support for generic axis to mixed chart

* fix tests + add new tests

* address review comments

* simplify control panel

* fix types and tests
2022-05-19 13:51:52 +03:00
cccs-RyanS ddc01ea781
feat(business-types): initial implementation of SIP-78 (#18794)
* add BUSINESS_TYPE_ADDONS to config with example callback

* Removing uneeded whitespace

* [Work in progress] Modifying cidr function to allow for  single ip and adding port outline

* Added test REST endpoint, added some more ports

I've thrown in a test.py script as well that will try to connect to the
business_type endpoint.

* Moving code from config.py into the business api

Very simple api is exposed that will allow someone to call a checkport
endpoint and get back a response.

* Removing commented out bits.

* Adding fucntion dict back to the config

* Moving business_type endpoint to charts

* Adding schema for get endpoint

* Removing imports, updating docstring, fixing typo

Just some small changes as described in the title.  I've updated the
test.py as well so it functions with the endpoint changes.

* Adding translation dict

* Fixing ops

* Adding check for list

* Modifying changes to add quotes where needed

Also changed BusinessTypeResponse to resp.

* Adding in some code to call the filter config

If a column starts with "cidr_" it will call the code in config.py to
try to translate the filter.  Nothing is changed in the JSON being
executed, just some information is dumped to console.

* Porting Ryan's changes

* Adding migration script (as per Ryan's PR)

* Fixing typo

* Prettier fixes

* [CLDN-1043] Adding rough version of filter changes for business types

* fix down migration

* Fixing bugs after merge

* adding functionality to appy filters in back end

* Fixing linting issues

* fix down revision

* Changing conversion callback to handle multiple values at once

* Adding string representation of values

* Code cleanup plus fixing debouce to only be called once for each entry

* Removing non needed logginh

* Changing operator list to use sting values

* Using text value operators

* Removing clear operator call

* Moving business type endpoints

* fix down revision

* Adding port functions

* update migration

* fix bad rebase and add ff

* implement validator

* dont add invalid values to response

* [CLDN-1205] Added a new exception type for a business type translation error. Added the error message in the display_value field within the business type response. Modified the IP and Port business types to populate the error message field in the response if an error occurs

* [CLDN-1205] Added meaningful error message for port translation errors

* Removing status field from businesstype Response and adding in error message

* [CLDN-1205] Added check to make sure the port business type is within the valid range of ports, if it is not, it will populate the error message

* [CLDN-1205] Fixed the if statement that checks to see if the string_value is in the valid range of port numbers. It did not corrently verify this before now.

* [CLDN-1205] Fixed an error where it was trying to use string_value in <= statements. I just casted string_value to an integer if it is numeric, which allows <= operators to be used on it

* [CLDN-1207] Added unit tests for the cidr_func and port_translation_func functions which are located in /superset/config.py

* [CLDN-1207] removed the assertRaises line as it does not work with the cidr_func and port_translation_func functions

* [CLDN-1207] Added the skeleton of the test_cidr_translate_filter_func unit test, still need to update what the expected response from the function will be.

* [CLDN-1207] Added the remainder of the back-end unit tests for the business types

* [CLDN-1207] Fixed the syntax error which caused the test_cidr_translate_filter_func_NOT_IN_double unit test to fail

* [CLDN-1207] Removed the logging that was added for debugging purposes

* [CLDN-1207] Formatted the commands_tests.py file to make it nicer to look at/read through

* [CLDN-1207] Fixed the code so that it conformed to the pylint requirements (i.e., pylint no longer complains about the code in commands_tests.py)

* [CLDN-1207] Modified some of the docstrings so they made better use of the 100 character per line, line limit

* [CLDN-1207] Added the beginnings of the unit tests for the
business types API

* [CLDN-1207] Added a comment to the top of the commands_tests.py file explaining how to run the unit tests. This prevents the next person who tries to run them from having to waste time trying the different forms of testing that Superset supports (e.g., pytest, tox, etc.)

* [CLDN-1207] Added a grammar fix to the comments describing how to run the unit tests

* [CLDN-1207] Modified the description of the business_type API endpoints as they did not represent what the API was actually doing

* [CLDN-1207] Added further instructions on how to run the unit tests that are within the business_type/api_tests.py file

* add request validation

* disable request if business type missing

* [CLDN-1207] Unit tests for the business type API are now working, however, they need to be modified to make use of @mock as we don't want to have to run the server to be able to run the unit tests

* Removing businesss types deffinitons from config

* Adding select to only show valid business types

* Fixed Enzyme tests

* Added scalfolding for selecting filter dropdown

* Adding intigration tests

* fix revision

* fix typos and unnecessary requests

* break out useBusinessTypes

* Added front-end RTL unit tests for the business type API endpoint

* Fixed error from unit tests

* Added a unit test to ensure the operator list is updated after a business type API response is received

* Removing elect compoenet for business types

* Adding feature flag and allowing saving when no business type present

* fixing useEffect hooks

* Adding feature flag to model

* Changing behavior such that an empty string returns a default response

* add form validation

* Modified comments in unit test as command to run test has changed

* Modified comments in unit test as filename to run test has changed

* Modified the api_tests.py file to conform to the linting requirements

* Changed the name of one of the tests to reflect what the test is actually testing

* Added cypress back to the package.json

* Added informative comments

* Updated comments in files as well as removed imports which were not being used

* Changes made by npm run prettier

* Fixed spelling mistakes

* Updated models.py to remove placeholder comments used in development

* Added feature flag mocking in unit test

* Fixing open api failure

* Fixing business types to pass unit tests

* Reverting unsafe connections back to false

* Removing print statement

* Adding business tpye to export test

* setting default feature flag to false for business type

* Reverting pre commit

* Reverting pre commit and running pre commit

* Reverting pre commit and running pre commit

* Fixing formatting

* Adding license

* Fixing Linting

* Protecting api enpoints

* updating model

* Fixing code path when business type exists

* Linting

* Linting

* Fixing linting

* Fixing spelling

* Fixing schemas

* Fixing app import

* fixing item render

* Added RTL test to make sure business type operator list is updated after API response

* Fixing linting

* fix migration

* Changing unit tests

* Fixing import and DB migration after rebase

* Renaming to advanced types

* Fixing Linting

* More renaming

* Removing uneeded change

* Fixing linting and test errors

* Removing unused imports

* linting

* Adding more detailed name for migration

* Moving files to plugins

* more renaming

* Fixing schema name

* Disabling feature flag that should not be enabled by default

* Adding extra cehck

* NameChange

* formatting

* Fixing equals check

* Moveing all advanced type classes and types to one file, and converting tests to functional

* Adding advanced type to test and fix linitng

Co-authored-by: Ville Brofeldt <ville.v.brofeldt@gmail.com>
Co-authored-by: Dan Parent <daniel.parent@cse-cst.gc.ca>
Co-authored-by: GITHUB_USERNAME <EMAIL>
Co-authored-by: cccs-Dustin <96579982+cccs-Dustin@users.noreply.github.com>
2022-05-16 17:58:21 +03:00
Stephen Liu 9854d2d0e8
feat(plugin-chart-echarts): support horizontal bar chart (#19918)
* feat(plugin-chart-echarts): support horizontal bar chart

* Update superset-frontend/plugins/plugin-chart-echarts/src/Timeseries/Regular/Bar/controlPanel.tsx

Co-authored-by: Evan Rusackas <evan@preset.io>

* Update superset-frontend/plugins/plugin-chart-echarts/src/Timeseries/transformProps.ts

Co-authored-by: Ville Brofeldt <33317356+villebro@users.noreply.github.com>

* Update superset-frontend/plugins/plugin-chart-echarts/src/Timeseries/transformProps.ts

Co-authored-by: Ville Brofeldt <33317356+villebro@users.noreply.github.com>

* Update superset-frontend/plugins/plugin-chart-echarts/src/Timeseries/Regular/Bar/controlPanel.tsx

Co-authored-by: Ville Brofeldt <33317356+villebro@users.noreply.github.com>

* improve controlpanel

* default value

* fix ut

Co-authored-by: Evan Rusackas <evan@preset.io>
Co-authored-by: Ville Brofeldt <33317356+villebro@users.noreply.github.com>
2022-05-16 21:48:36 +08:00
Kamil Gabryjelski 0f68deedf1
perf(plugin-chart-table): Add memoization to avoid rerenders (#19976)
* perf(plugin-chart-table): Add memoization to avoid rerenders

* Fix typing
2022-05-13 18:10:48 +02:00
Ville Brofeldt b53daa91ec
fix(plugin-chart-echarts): support adhoc x-axis (#20055)
* fix(plugin-chart-echarts): support adhoc x-axis

* simplify code
2022-05-13 16:29:51 +03:00
Lily Kuang 3e36d4a0a1
fix(embedded): third party cookies (#20019)
* debugging

* logging

* add comment

* remove logging

* Update superset-frontend/packages/superset-ui-core/src/connection/callApi/callApi.ts

Co-authored-by: David Aaron Suddjian <1858430+suddjian@users.noreply.github.com>

Co-authored-by: David Aaron Suddjian <aasuddjian@gmail.com>
Co-authored-by: David Aaron Suddjian <1858430+suddjian@users.noreply.github.com>
2022-05-11 14:42:46 -07:00
Michael S. Molina b7cff8335b
chore: Removes hard-coded colors from the plugins - iteration 1 (#19923)
* chore: Removes hard-coded colors from the plugins - iteration 1

* Fixes lint errors

* Fixes tests
2022-05-09 10:44:13 -03:00
Michael S. Molina e9032e95ec
chore: Adds theme object to chart properties (#19951) 2022-05-04 09:55:22 -03:00
Hugh A. Miles II 8b15b68979
fix: Alpha should not be able to edit datasets that they don't own (#19854)
* fix api for checking owners

* fix styles for disabling

* fix styles for disabling

* fix lint

* fix lint

* add owners key

* plzz

* remove

* update test

* add tooltip

* add type

* fix test

* fix user reference

* lit

* fix test

* work
2022-04-29 14:21:05 -07:00
Diego Medina e4fca89217
fix: Cannot re-order metrics by drag and drop (#19876)
* fix: cannot-re-order-metrics-by-drag-and-drop

* add tests
2022-04-27 20:37:12 -06:00
Yongjie Zhao f5e9f0eb3b
feat: add Advanced Analytics into mixed time series chart (#19851) 2022-04-27 23:36:19 +08:00
Josh Soref bebb10e495
chore(frontend-tests): Spelling (#19853)
* spelling: against

Signed-off-by: Josh Soref <jsoref@users.noreply.github.com>

* spelling: been

Signed-off-by: Josh Soref <jsoref@users.noreply.github.com>

* spelling: charts

Signed-off-by: Josh Soref <jsoref@users.noreply.github.com>

* spelling: clicking

Signed-off-by: Josh Soref <jsoref@users.noreply.github.com>

* spelling: columns

Signed-off-by: Josh Soref <jsoref@users.noreply.github.com>

* spelling: duplicate

Signed-off-by: Josh Soref <jsoref@users.noreply.github.com>

* spelling: especially

Signed-off-by: Josh Soref <jsoref@users.noreply.github.com>

* spelling: extensions

Signed-off-by: Josh Soref <jsoref@users.noreply.github.com>

* spelling: fields

Signed-off-by: Josh Soref <jsoref@users.noreply.github.com>

* spelling: filter

Signed-off-by: Josh Soref <jsoref@users.noreply.github.com>

* spelling: for

Signed-off-by: Josh Soref <jsoref@users.noreply.github.com>

* spelling: label

Signed-off-by: Josh Soref <jsoref@users.noreply.github.com>

* spelling: labeled

Signed-off-by: Josh Soref <jsoref@users.noreply.github.com>

* spelling: nativefilter

Signed-off-by: Josh Soref <jsoref@users.noreply.github.com>

* spelling: registry

Signed-off-by: Josh Soref <jsoref@users.noreply.github.com>

* spelling: render

Signed-off-by: Josh Soref <jsoref@users.noreply.github.com>

* spelling: resizable

Signed-off-by: Josh Soref <jsoref@users.noreply.github.com>

* spelling: response

Signed-off-by: Josh Soref <jsoref@users.noreply.github.com>

* spelling: successful

Signed-off-by: Josh Soref <jsoref@users.noreply.github.com>

* spelling: transform

Signed-off-by: Josh Soref <jsoref@users.noreply.github.com>

* spelling: unfortunately

Signed-off-by: Josh Soref <jsoref@users.noreply.github.com>

* spelling: until

Signed-off-by: Josh Soref <jsoref@users.noreply.github.com>

* spelling: virtual

Signed-off-by: Josh Soref <jsoref@users.noreply.github.com>

* spelling: wrapper

Signed-off-by: Josh Soref <jsoref@users.noreply.github.com>

Co-authored-by: Josh Soref <jsoref@users.noreply.github.com>
2022-04-26 10:35:01 -07:00
Josh Soref c32c505742
chore(docs): Spelling (#19675)
* spelling: adding

Signed-off-by: Josh Soref <jsoref@users.noreply.github.com>

* spelling: aggregate

Signed-off-by: Josh Soref <jsoref@users.noreply.github.com>

* spelling: avoid

Signed-off-by: Josh Soref <jsoref@users.noreply.github.com>

* spelling: blacklist

Signed-off-by: Josh Soref <jsoref@users.noreply.github.com>

* spelling: cached

Signed-off-by: Josh Soref <jsoref@users.noreply.github.com>

* spelling: discontinue

Signed-off-by: Josh Soref <jsoref@users.noreply.github.com>

* spelling: exhaustive

Signed-off-by: Josh Soref <jsoref@users.noreply.github.com>

* spelling: from

Signed-off-by: Josh Soref <jsoref@users.noreply.github.com>

* spelling: github

Signed-off-by: Josh Soref <jsoref@users.noreply.github.com>

* spelling: hybrid

Signed-off-by: Josh Soref <jsoref@users.noreply.github.com>

* spelling: implicit

Signed-off-by: Josh Soref <jsoref@users.noreply.github.com>

* spelling: interim

Signed-off-by: Josh Soref <jsoref@users.noreply.github.com>

* spelling: introduced

Signed-off-by: Josh Soref <jsoref@users.noreply.github.com>

* spelling: javascript

Signed-off-by: Josh Soref <jsoref@users.noreply.github.com>

* spelling: logstash

Signed-off-by: Josh Soref <jsoref@users.noreply.github.com>

* spelling: metadata

Signed-off-by: Josh Soref <jsoref@users.noreply.github.com>

* spelling: password

Signed-off-by: Josh Soref <jsoref@users.noreply.github.com>

* spelling: recommended

Signed-off-by: Josh Soref <jsoref@users.noreply.github.com>

* spelling: redshift

Signed-off-by: Josh Soref <jsoref@users.noreply.github.com>

* spelling: refactored

Signed-off-by: Josh Soref <jsoref@users.noreply.github.com>

* spelling: referencing

Signed-off-by: Josh Soref <jsoref@users.noreply.github.com>

* spelling: sqlite

Signed-off-by: Josh Soref <jsoref@users.noreply.github.com>

* spelling: the

Signed-off-by: Josh Soref <jsoref@users.noreply.github.com>

* spelling: thumbnails

Signed-off-by: Josh Soref <jsoref@users.noreply.github.com>

* spelling: undoes

Signed-off-by: Josh Soref <jsoref@users.noreply.github.com>

* spelling: very

Signed-off-by: Josh Soref <jsoref@users.noreply.github.com>

Co-authored-by: Josh Soref <jsoref@users.noreply.github.com>
2022-04-26 13:17:15 -03:00
dependabot[bot] e98199d43d
chore(deps): bump @types/d3-time in /superset-frontend (#17978)
Bumps [@types/d3-time](https://github.com/DefinitelyTyped/DefinitelyTyped/tree/HEAD/types/d3-time) from 1.1.1 to 3.0.0.
- [Release notes](https://github.com/DefinitelyTyped/DefinitelyTyped/releases)
- [Commits](https://github.com/DefinitelyTyped/DefinitelyTyped/commits/HEAD/types/d3-time)

---
updated-dependencies:
- dependency-name: "@types/d3-time"
  dependency-type: direct:production
  update-type: version-update:semver-major
...

Signed-off-by: dependabot[bot] <support@github.com>

Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2022-04-22 14:50:43 -06:00
Kamil Gabryjelski 12bc30e2c7
Fix display of column config in table chart (#19806) 2022-04-21 19:08:04 +02:00
Stephen Liu e3a54aa3c1
feat(explore): improve UI in the control panel (#19748)
* feat(explore): improve section header of control panel

* fix checkbox control color and radio button color
2022-04-20 15:06:33 +02:00
Yongjie Zhao 4f997cd9ac
chore: fix grammar error (#19740) 2022-04-20 21:02:14 +08:00
Yongjie Zhao 3c28cd4625
feat: add renameOperator (#19776) 2022-04-20 19:48:12 +08:00
Geido b8e595413f
fix: Redirect to full url on 401 (#19357)
* Redirect to full url

* Redirect to full url

* Update test
2022-04-15 20:15:30 +02:00
David Aaron Suddjian 4927685c30
feat: UI override registry (#19671)
* typed registry

* remove unintentional change

* lint

* fix
2022-04-14 08:44:26 -07:00
Yongjie Zhao 9425dd2cac
fix: drop the first level of MultiIndex (#19716) 2022-04-14 23:40:38 +08:00
Jesse Yang 32a9265cc0
fix(nav): infinite redirect and upload dataset nav permissions (#19708) 2022-04-13 23:29:56 -07:00
Kamil Gabryjelski de9fb2109d
chore(explore): Change labels "Group by"/"Series" to "Dimensions" (#19647) 2022-04-13 15:16:03 +02:00
Kamil Gabryjelski 4a5dddf52d
fix(explore): Change copy of cross filters checkbox (#19646) 2022-04-13 13:19:02 +02:00
Yongjie Zhao 761d5c4208
chore: cleanup as unknown conversion (#19587) 2022-04-08 17:32:29 +08:00
Michael S. Molina 38fbca10e3
refactor: Removes the CSS files from the Parallel Coordinates plugin (#19539)
* refactor: Removes the CSS files from the Parallel Coordinates plugin

* Adds test

* Fixes indentation
2022-04-07 11:51:08 -03:00
Stephen Liu 0e29871493
fix(explore): clean data when hidding control (#19039) 2022-04-06 20:25:32 +08:00
Geido 2de5e6fac4
chore: Remove Legacy Force Directed viz plugin (#19492)
* Add theme vars

* Remove plugin
2022-04-06 11:51:51 +03:00
Kamil Gabryjelski 60dcd651f4
feat(explore): SQL popover in datasource panel (#19308)
* feat(explore): SQL popover in datasource panel

* Fix acequire not defined

* Rebase and fix tests

* Disable highlighting gutter

* Use ace-build acequire instead of brace
2022-04-03 13:26:56 +02:00
Stephen Liu 90c9daea08
feat(color): support analogous colors to prevent color conflict (#19325)
* feat(color): support analogous colors

* fix test

* fix range

* add some comment
2022-04-01 18:42:30 +03:00
Kamil Gabryjelski a076ae6d99
feat(explore): UI changes in dataset panel on Explore page (#19394)
* feat(explore): Implement new design for dataset panel

* Fixes

* Replace drag handle in dashboard builder

* Add missing types

* Type fix

* Fix tests

* Fix non-dnd version

* Fix test

* Replace margin with height
2022-03-29 21:11:08 +02:00
Yongjie Zhao a39dd4493e
feat: linear imputation in Resample (#19393) 2022-03-28 22:30:45 +08:00
Stephen Liu 6f5778273e
chore: add type checking in plugin test directory (#19387) 2022-03-28 10:20:06 +08:00
Kamil Gabryjelski 45c28c8046
feat(explore): Dataset panel option tooltips (#19259)
* feat(explore): Add description to column/metric tooltips in dataset panel

* Fix tests

* Address code review comments
2022-03-25 07:55:11 +01:00
Yongjie Zhao e15573d445
fix: number format should editable when AA in time comparison (#19351) 2022-03-25 07:58:53 +08:00
Kasia dc769a9a34
fix: Adaptive formatting spelling (#19359)
Co-authored-by: Kasia Zajac <kasiazajac@Kasias-MacBook-Pro-2.local>
2022-03-24 20:51:06 +01:00
Erik Ritter 2af2d00e85
fix: typo on doc string (#19346) 2022-03-24 09:15:56 +00:00
Stephen Liu b0397beb8e
chore: add type checking in package tests directory (#19320) 2022-03-23 18:57:35 +08:00
Yongjie Zhao 375c03e084
feat(advanced analysis): support MultiIndex column in post processing stage (#19116) 2022-03-23 13:46:28 +08:00
Kamil Gabryjelski a8a48af7fa
chore: Make font-weights themable, fix font faces (#19236)
* fix(fonts): Import all necessary font packages

* Make html tags themable

* Set bold font weight to 600, add medium font weight to theme

* Replace hard coded font weights with theme variables

* Change some font weight light elements to normal

* Fix tests

* Fix bug in pivot table

* Address code review comments
2022-03-22 09:36:15 +01:00
David Aaron Suddjian 96a123f553
feat: SupersetClient config to override 401 behavior (#19144)
* wip

* feat: make 401 responses configurable in SupersetClient

* sort

* guest unauthorized handler

* add toast container to embedded app

* add option for toast presenter to go at the top

* remove confusing comms logging

* lint

* Update superset-frontend/src/embedded/index.tsx

* type correction
2022-03-21 10:19:21 -07:00
Stephen Liu dc575080d7
feat: improve color consistency (save all labels) (#19038) 2022-03-21 15:20:04 +08:00
Ville Brofeldt f341025d80
feat: add support for comments in adhoc clauses (#19248)
* feat: add support for comments in adhoc clauses

* sanitize remaining freeform clauses

* sanitize adhoc having in frontend

* address review comment
2022-03-18 15:08:06 -07:00
David Aaron Suddjian 97abc28a1f
chore!: remove `ENABLE_REACT_CRUD_VIEWS` feature flag (permanently enable) (#19231)
* remove ENABLE_REACT_CRUD_VIEWS feature flag

* docs

* deal with problematic tests

* empty test suite

* skip test

* test conditions changed

* removing the tests instead of skipping
2022-03-18 14:00:23 -07:00
Grace Guo d41f9b23a4
chore(superset 2.0): remove front-end deprecated code (#19241) 2022-03-18 11:23:00 -07:00
smileydev e7355b9610
fix(explore comma): make that the comma can be added by removing it from token separators… (#18926)
* make that the comma can be added by removing it from token separators in select component.

* fix(explore comma): add the allowTokenSeperators props into Select

* fix(explore comma): make to allow to customize the token separators in Select.

* fix(explore comma): make to add the unit test and story book.

* fix(explore comma): make to fix the lint

* fix(explore comma): make to fix the spell  & add tokenSeparatprs props to PickedSelectProps

* Update Select.tsx

* fix(explore comma): make to run lint fix
2022-03-18 11:39:26 -03:00
Stephen Liu 10eb6c77a4
chore: use order_desc shared control consistently (#19172) 2022-03-18 21:28:47 +08:00
smileydev d099f5ed4a
fix(select): make to consider the case sensitive in case of d3 format selector (#19159) 2022-03-17 10:04:03 -07:00
David Aaron Suddjian 3d66912d89
fix: clean up chart metadata config (#19143)
* fix: clean up chart metadata config

* missed a spot

* missed another spot

* fix failing time-specific test

* can't call translation functions here

* Revert "fix failing time-specific test"

This reverts commit 3eeb8ab9cc.

* skip problematic test

* extra import
2022-03-16 09:59:56 -07:00
David Aaron Suddjian 54b60ded8e
chore(embedded): refresh the guest token (#19132)
* refresh the guest token

* put back the date logic

* version

* fix time hijinks

* test

* Update superset-embedded-sdk/src/guestTokenRefresh.ts
2022-03-14 09:32:25 -07:00
Evan Rusackas 76b4a14d30
chore(config): Migrating `ENABLE_JAVASCRIPT_CONTROLS` from app config to a feature flag (#19113)
* first pass migrating config to ff

* nixing a console log from testing

* adding an entry to `UPDATING.md`

* linting 

* Adding ENABLE_JAVASCRIPT_CONTROLS to FEATURE_FLAGS.md

* no longer in need of state!

* Turning the flag back off

* linting... le sigh

* and more linting...
2022-03-14 08:54:02 -06:00
Jesse Yang ae13d8313b
feat(select): keep options order when in single mode (#19085) 2022-03-11 13:01:38 -08:00
Stephen Liu 7524e1e3c8
feat(viz-gallery): add 'feature' tag and fuzzy search weighting (#18662)
* feat(viz-gallery): add 'feature' tag and fuzzy search weighting

* add search weight

* Update superset-frontend/src/explore/components/controls/VizTypeControl/VizTypeGallery.tsx

Co-authored-by: Evan Rusackas <evan@preset.io>

* Update superset-frontend/src/explore/components/controls/VizTypeControl/VizTypeGallery.tsx

Co-authored-by: Evan Rusackas <evan@preset.io>

* Update superset-frontend/src/explore/components/controls/VizTypeControl/VizTypeGallery.tsx

Co-authored-by: Evan Rusackas <evan@preset.io>

* Update superset-frontend/src/explore/components/controls/VizTypeControl/VizTypeGallery.tsx

Co-authored-by: Evan Rusackas <evan@preset.io>

* some improvements

* take metadata out

* use chartLabel enum to unify

* add test chart

* fix cache

* Resolving TS Lint issue

* Appeasing the linter

* Removing one example implementation

* Removing another example label implementation

* Removing the third example label implementation

Co-authored-by: Evan Rusackas <evan@preset.io>
2022-03-11 01:49:10 -07:00
Diego Medina 0e0beceac1
fix: Pivot Table Conditional Formatting Doesn't Show All Options (#19071)
* fix: Pivot Table Conditional Formatting Doesn't Show All Options

* PR comments

* PR comments
2022-03-09 15:04:04 -07:00
Geido f53f86f796
Control sortby based on series limit (#18950) 2022-03-09 20:12:45 +02:00
Kamil Gabryjelski 9f834e8317
fix(plugin-chart-echarts): Apply temporary filters to Query B in explore (#18998)
* fix(explore): Extra filters not applied to query b in mixed timeseries

* Add return type

* Apply review comment

* Fix non-dnd filters
2022-03-04 17:48:41 +01:00
Michael S. Molina 06e1e4285e
feat: Adds support to multiple dependencies to the native filters (#18793)
* chore(native-filters): Remove cascading popovers from filter bar

Co-authored-by: Kamil Gabryjelski <kamil.gabryjelski@gmail.com>
2022-03-04 13:06:10 -03:00
John Bodley 26486d01c1
chore: Remove legacy SIP-15 interim logic/flags (#18936)
* chore: Remove legacy SIP-15 logic

* Update ab9a9d86e695_deprecate_time_range_endpoints.py

* Update UPDATING.md

* Update UPDATING.md

* Update UPDATING.md

Co-authored-by: John Bodley <john.bodley@airbnb.com>
2022-03-04 09:15:36 +13:00
Geido eafe0cfc6f
fix(Explore): Pivot table V2 sort by failure with D&D enabled (#18835)
* wip

* Add tests and clean up

* Clean up

* Remove unused import
2022-02-28 18:56:13 +02:00
Kamil Gabryjelski c56dc8eace
feat(legacy-preset-chart-deckgl): Add ,.1f and ,.2f value formats to deckgl charts (#18945)
* Add ,.1f and ,.2f value formats to deckgl charts

* Remove duplicated code
2022-02-28 14:07:55 +01:00
David Aaron Suddjian 97a879ef27
chore: use switchboard as dependency for embedded sdk (#18728) 2022-02-15 11:53:58 -08:00
Geido 8027f5f0a6
fix: Only redirect to relative paths when authentication expires (#18714)
* Only redirect to relative paths

* Fix redirect test
2022-02-15 16:59:06 +02:00
Kamil Gabryjelski 167e18e806
feat(explore): Implement chart empty states (#18678)
* feat(explore): Implement chart empty states

* Fix test

* Remove unused import

* Fix tests
2022-02-14 16:14:20 +01:00
Kamil Gabryjelski c1205b5279
feat(explore): Implement metrics and columns popovers empty states (#18681)
* feat(explore): Implement empty states for column and metrics popovers

* Fix test

* Change copy
2022-02-14 15:26:56 +01:00
David Aaron Suddjian 225015fd5a
feat: Introduce a library for embedded iframe <-> host communication (#18652)
* improved logging

* switchboard, and window size

* lint

* tsconfig

* fix path

* fix release script

* tests, debug mode, and error handling

* moar debug mode

* package lock

* formatting

* comment

* wording

* appease the coverage gods

* Async assertions must be awaited or returned
2022-02-11 20:29:23 -08:00
simcha90 bcad1acec2
feat: Dynamic dashboard component (#17208)
* fix:fix get permission function

* feat: dynamic loading of dashboard components

* fix: revert image

* fix: fix py

* fix: fix py

* fix: pass state to dynamic component

* lint: add typing

* lint: fix lint

* lint: fix lint

* refactor: re-run pipeline

* fix: fix CR notes

* fix: fix CR notes

* move types and interfaces to core

* reorder exports

* rename Scope and Target

Co-authored-by: Ville Brofeldt <ville.v.brofeldt@gmail.com>
2022-02-09 17:44:40 +02:00
Yongjie Zhao aa21a963a6
feat: smart tooltip in datasourcepanel (#18080) 2022-02-07 22:48:23 +08:00
Ville Brofeldt 2929bb1680
fix(plugin-chart-echarts): fix forecasts on verbose metrics (#18252)
* fix(plugin-chart-echarts): fix forecasts on verbose metrics

* oops! 🙊

* check for DTTM_ALIAS
2022-02-02 13:51:51 +02:00
David Aaron Suddjian 4ad5ad045a
feat: embedded dashboard core (#17530)
* feat(dashboard): embedded dashboard UI configuration (#17175) (#17450)

* setup embedded provider

* update ui configuration

* fix test

* feat: Guest token (for embedded dashboard auth) (#17517)

* generate an embed token

* improve existing tests

* add some auth setup, and rename token

* fix the stuff for compatibility with external request loaders

* docs, standard jwt claims, tweaks

* black

* lint

* tests, and safer token decoding

* linting

* type annotation

* prettier

* add feature flag

* quiet pylint

* apparently typing is a problem again

* Make guest role name configurable

* fake being a non-anonymous user

* just one log entry

* customizable algo

* lint

* lint again

* 403 works now!

* get guest token from header instead of cookie

* Revert "403 works now!"

This reverts commit df2f49a6d4.

* fix tests

* Revert "Revert "403 works now!""

This reverts commit 883dff38f1.

* rename method

* correct import

* feat: entry for embedded dashboard (#17529)

* create entry for embedded dashboard in webpack

* add cookies

* lint

* token message handshake

* guestTokenHeaderName

* use setupClient instead of calling configure

* rename the webpack chunk

* simplified handshake

* embedded entrypoint: render a proper app

* make the embedded page accept anonymous connections

* format

* lint

* fix test
# Conflicts:
#	superset-frontend/src/embedded/index.tsx
#	superset/views/core.py

* lint

* Update superset-frontend/src/embedded/index.tsx

Co-authored-by: David Aaron Suddjian <1858430+suddjian@users.noreply.github.com>

* comment out origins checks

* move embedded for core to dashboard

* pylint

* isort

Co-authored-by: David Aaron Suddjian <aasuddjian@gmail.com>
Co-authored-by: David Aaron Suddjian <1858430+suddjian@users.noreply.github.com>

* feat: Authorizing guest access to embedded dashboards (#17757)

* helper methods and dashboard access

* guest token dashboard authz

* adjust csrf exempt list

* eums don't work that way

* Remove unnecessary import

* move row level security tests to their own file

* a bit of refactoring

* add guest token security tests

* refactor tests

* clean imports

* variable names can be too long apparently

* missing argument to get_user_roles

* don't redefine builtins

* remove unused imports

* fix test import

* default to global user when getting roles

* missing import

* mock it

* test get_user_roles

* infer g.user for ease of tests

* remove redundant check

* tests for guest user security manager fns

* use algo to get rid of warning messages

* tweaking access checks

* fix guest token security tests

* missing imports

* more tests

* more testing and also some small refactoring

* move validation out of parsing

* fix dashboard access check again

* add more test

Co-authored-by: Lily Kuang <lily@preset.io>

* feat: Row Level Security rules for guest tokens (#17836)

* helper methods and dashboard access

* guest token dashboard authz

* adjust csrf exempt list

* eums don't work that way

* Remove unnecessary import

* move row level security tests to their own file

* a bit of refactoring

* add guest token security tests

* refactor tests

* clean imports

* variable names can be too long apparently

* missing argument to get_user_roles

* don't redefine builtins

* remove unused imports

* fix test import

* default to global user when getting roles

* missing import

* mock it

* test get_user_roles

* infer g.user for ease of tests

* remove redundant check

* tests for guest user security manager fns

* use algo to get rid of warning messages

* tweaking access checks

* fix guest token security tests

* missing imports

* more tests

* more testing and also some small refactoring

* move validation out of parsing

* fix dashboard access check again

* rls rules for guest tokens

* test guest token rls rules

* more flexible rls rules

* lint

* fix tests

* fix test

* defaults

* fix some tests

* fix some tests

* lint

Co-authored-by: Lily Kuang <lily@preset.io>

* SupersetClient guest token test

* Apply suggestions from code review

Co-authored-by: Lily Kuang <lily@preset.io>

Co-authored-by: Lily Kuang <lily@preset.io>
2022-01-25 16:41:32 -08:00
jayakrishnankk 4b89ac7447
chore: migrating storybook jsx to typescript #18100 (#18133)
* Migrating storybook jsx to typescript #18100

* Migrating storybook jsx to typescript

Co-authored-by: Jayakrishnan Karolil <jayakrishnan.karolil@nielsen.com>
2022-01-24 14:32:18 +08:00
Ville Brofeldt e9651ea52f
feat(plugin-chart-echarts): support non-timeseries x-axis (#17917)
* feat(plugin-chart-echarts): support non-timeseries x-axis

* fix tests

* change formula return type from Date to number

* add x_axis test coverage

* rename func and improve coverage

* add x-axis control to bar chart

* remove redundant console.log

* fix description

* make x-axis control mandatory

* 🙃

* fix x-axis formatter

* fix showValues

* fix implicit rDTTM_ALIAS references in postProcessing

* replace TIME_COLUMN with DTTM_ALIAS

* fix remaining implicit indexes

* fix: Disable filtering on wide result sets (#18021)

* fix: handle null values in time-series table (#18039)

* cleanup column_type_mappings (#17569)

Signed-off-by: Đặng Minh Dũng <dungdm93@live.com>

* important change to MakeFile (#18037)

* add missing is_timeseries to pivot op

Co-authored-by: Erik Ritter <erik.ritter@airbnb.com>
Co-authored-by: Grace Guo <grace.guo@airbnb.com>
Co-authored-by: Đặng Minh Dũng <dungdm93@live.com>
Co-authored-by: AAfghahi <48933336+AAfghahi@users.noreply.github.com>
2022-01-21 21:23:23 +02:00
Ville Brofeldt 5bfe2d47b0
fix(generator): add lockfile and fix styling issues (#18073)
* fix(generator): add lockfile and fix styling issues

* fix margins and remove redundant scroll

* update tutorial
2022-01-18 12:37:09 +02:00
Yongjie Zhao 0c7f7288d8
feat(advanced analytics): support groupby in resample (#18045) 2022-01-17 18:42:59 +08:00
Ville Brofeldt 8dea7f500b
fix(generator): more cleanup to plugin framework (#18027)
* fix(generator): more cleanup to plugin framework

* fix typo and package name

* add docs

* fix typo

* Update superset-frontend/webpack.config.js

Co-authored-by: Kamil Gabryjelski <kamil.gabryjelski@gmail.com>

* fix generator reference

* add steps to tutorial and fix package version

* refine docs/readme

Co-authored-by: Kamil Gabryjelski <kamil.gabryjelski@gmail.com>
2022-01-17 10:23:35 +02:00
Corbin Robb 6bd4dd257a
feat(timeseries-chart): add percentage threshold input control (#17758)
* feat(timeseries-chart): add percentage threshold control for stack series labels

* feat: move threshold vlues to an array

* add tests for showValue, onlyTotal, and percentThreshold

* feat: add another test

* revert ChartProps typesetting, fix misnamed variable on form data type, and other minor changes

* fix percentage threshold push equation

* fix percentage threshold push equation in tests

* change default on control to match form

* attempt fix form defaults import

Co-authored-by: Corbin Robb <corbin@Corbins-MacBook-Pro.local>
2022-01-12 14:46:27 -06:00
AAfghahi 536ca1f62c
chore(DatasourceEditor): Create Datasource Legacy Editor Feature Flag (#18003)
* a lot of console logs

* adding new feature flag for datasource editor
2022-01-12 14:02:53 -05:00
Yongjie Zhao d8d47ce054
chore: reenable lint for test files (#17979)
* chore: reenable lint for test files

* fix comments
2022-01-11 14:22:56 +08:00
Yongjie Zhao e91b9a678f
refactor: move superset-ui dependencies to peerDependencies (#17965)
* chore: add commit message

* update learn

* update superset-ui-demo

* move superset-ui into peerDeps

* add --no-private argument in lerna version

* fix conflicts

* refresh lock file
2022-01-11 13:53:37 +08:00
serenajiang 05d9cde203
feat: update time comparison choices (again) (#17968) 2022-01-10 10:08:15 -08:00
Evan Rusackas c0a769581f
chore: bump typescript to 4.5.4, and adjust storybook story. (#17971)
* chore: bump typescript to 4.5.4, and adjust storybook story to pass linting

* ugh... missed a space. Thanks, linter :)

* nixing erroneous package lock file
2022-01-09 21:01:59 -07:00
Yongjie Zhao cb97e37a92
refactor: import value name from root of superset-ui/core (#17947)
* chart

* index and number-format

* char-composition and color

* connection

* dimension and math-expression

* models

* query

* time-format

* residual modules

* change config of jest and eslint

config

* wip

update package.json

* fix lint

* WithLegend import from superset-ui/core
2022-01-08 09:16:24 +08:00
Yongjie Zhao 97a78d3301
refactor(storybok): upgrade to webpack5 in storybook of plugins (#17909)
* refactor: use webpack5 in plugins storybook

* remove ./src from packages.json
2022-01-05 10:39:33 +08:00
David Aaron Suddjian de3d3973a2
fix: process color scheme configs correctly (#17786) 2022-01-04 15:27:10 -08:00
Ville Brofeldt 19daf65b54
chore(generator-superset): migrate to monorepo (#17829)
* chore(generator-superset): migrate to monorepo

* add todo and remove webpack reference from template

* fix linting errors

* remove redundant test file
2021-12-21 11:44:21 +02:00
Kamil Gabryjelski 124af4c566
chore(explore): Migrate BigNumber to v1 api [ID-28][ID-55] (#17587)
* chore(explore): Migrate BigNumber to v1 api

* Move to echarts

* Use Echarts trendline

* Fix imports

* Fix parsing dates as strings

* Add from_dttm and to_dttm to v1 chart response

* Fix post processing

* Fix timeRangeFixed

* Fix tests

* Remove from and to dttm from cache

* Cleanup date formatting

* Fix storybook

* Fix missing types

* Fix timestamp with timezone

* Add types to demo's tsconfig

* bug fix

* fix import

* Fix cypress tests

* add sort

* add resample to handle missing values properly

* Sync ChartDataResponseResult schema with ts interface

* Lint fix

* Add migration

* Fix migration

* Remove pass

* Re-raise the exception in migration

* Typo fix

* Update revision

Co-authored-by: Ville Brofeldt <ville.v.brofeldt@gmail.com>
2021-12-15 10:15:14 +01:00
Stephen Liu 142b5bc506
fix: local warning in the frontend development (#17727) 2021-12-15 09:52:42 +02:00
Yongjie Zhao 07bbe8448b
refactor(monorepo): change coverage of core to 100% (#17698) 2021-12-14 16:19:55 +08:00
Corbin Robb f476ba23a2
fix(select): select component sort functionality on certain options (#17638)
* fix: Select component sort function sorting by label instead of value on numbers

* fix: change select component default sorting to sort by the initial index rather than a property like value or label

* fix: select sorting add sortOptions to select components using sortByProperty

* fix: change select component back, add order to options coming in from SelectControl

* fix: select component options intitial sort bug

* fix: add test cases for select fix

Co-authored-by: Corbin Robb <corbin@Corbins-MacBook-Pro.local>
2021-12-09 11:40:25 -05:00
Yongjie Zhao 04e3cfa607
refactor(monorepo): relocate deckgl to Superset (#17596) 2021-12-09 08:45:18 +08:00
Geido 46cdc77ae6
fix: Redirect on 401 (#17597)
* Redirect on 401

* Bump FAB

* Format

* Update Cypress save test

* Revert Cypress change

* Bump FAB 3.4.1rc2

* Update test

* Update return statement

* Update api test

* Update datasets api test

* Update datasets api 401s to 403s

* Add typeguard

* Use Promise.resolve

* Update callApiAndParseWithhTimeout test

* Disable parseResponse test

* Try catch

* Handle npm 8 issues
2021-12-08 13:14:30 -07:00
Yongjie Zhao 4306289bfc
refactor(monorepo): frontend code cleanup after monorepo (#17639)
* chore: frontend cleanup

* remove unused files

* remove stylelint

* arrange tsconfig

* updates
2021-12-04 10:55:04 +08:00
Kamil Gabryjelski 07e8837093
feat(explore): export csv data pivoted for Pivot Table [ID-9] (#17512)
* feat(explore): export csv data pivoted for Pivot Table

* Implement dropdown with download csv options

* Change label to "Original"

* Add tests

* Add form data to query context

* Add form data to query context generator

* Explicitly make form_data optional
2021-12-03 12:42:28 +01:00
Jesse Yang 73e7928c4b
chore(superset-ui): clean up legacy-plugin-chart-time-table (#17626) 2021-12-02 17:14:10 -08:00
Yongjie Zhao 3c41ff68a4
refactor(monorepo): move superset-ui to superset(stage 2) (#17552) 2021-11-30 08:29:57 +08:00