Commit Graph

7187 Commits (eadd53053b8b08d4feb4baf5c69133ac19786de4)

Author SHA1 Message Date
Alex P 874e0a2e10 Refactor instances of Overlay Technology to new pattern 2018-06-25 19:17:05 -07:00
Alex P b76e2be6c1 Refactor overlay technology to not use redux store 2018-06-25 19:16:39 -07:00
Jared Scheib f4ab45d420 Merge pull request #3739 from influxdata/fun/dashboard_page
Convert DashboardPage to TypeScript & introduce improved file structure for types
2018-06-25 17:23:39 -07:00
Jared Scheib 3125f23b16 Rename types/query to types/queries for consistency 2018-06-25 17:10:34 -07:00
Jared Scheib 14704686c5 Revert introduction of /modules for single importable Types
After discussion with team, folks felt that it was too explicit and verbose
to import * as Types and use Types.*.*.x for all type annotations. So we
decided to try importing, for example, all dashboard action types under
a single import * as DashboardsActions from 'src/types/actions/dashboards'.
2018-06-25 17:07:56 -07:00
Jared Scheib 9b585f5087 Merge duplicate imports in test fixtures file 2018-06-25 15:49:58 -07:00
Alex P 84f51b5d97 Resurrect favicon 2018-06-25 15:47:45 -07:00
Jared Scheib 96864064fa Simplify getNewDashboardCell default value for cell type
Co-authored-by: Alirie Gray<alirie.gray@gmail.com>
2018-06-25 15:47:32 -07:00
Jared Scheib 4153af9f64 Simplify naming of showOverlay import in FluxHeader 2018-06-25 15:45:04 -07:00
Andrew Watkins de4e189c86 Update crosshair on mousemove 2018-06-25 15:44:12 -07:00
Jared Scheib 810b750888 Refactor HostPage mapDispatchToProps to simpler object syntax & remove bindActionCreators 2018-06-25 15:41:57 -07:00
Alex Paxton e24e87eb22 Merge pull request #3762 from influxdata/polish-user-nav-icons
Make User Nav Icon Consistent
2018-06-25 12:32:03 -07:00
Alex P 07296d65d3 Make user nav icons consistent with other nav icons 2018-06-25 11:45:08 -07:00
Brandon Farmer 54c0c01a0c Fix dashboards crashing by making some performance optimizations
Co-authored-by: Brandon Farmer <bthesorceror@gmail.com>
2018-06-25 11:43:09 -07:00
Iris Scholten 93f11fb4e6 Merge pull request #3759 from influxdata/fix/unselect-yformat
Change axes options to have valid defaults
2018-06-25 10:07:13 -07:00
Iris Scholten 15ca96c53b Remove unused import 2018-06-25 09:21:53 -07:00
Jared Scheib 88abfcf9ee Refactor all type imports modified in #3739 to unified Types ns 2018-06-23 13:55:55 -07:00
Jared Scheib c17eee8258 Refactor dashboards/actions/index to use new Types namespace 2018-06-23 13:16:26 -07:00
Jared Scheib a19ed861ce Add Auth to Types module & sort module index by alpha 2018-06-23 13:09:22 -07:00
Jared Scheib 20a84023e5 Rename types/apis/dashboard.ts dashboards.ts for consistency 2018-06-23 13:03:44 -07:00
Jared Scheib 9a5dfcb57d Create global Types module & consume in DashboardPage for single import 2018-06-23 12:54:24 -07:00
Jared Scheib 7e25bb554b Make all type imports consistent & group all imports 2018-06-23 11:41:14 -07:00
Jared Scheib 65da5cc724 Fix dashboardActions undefined by de-nesting all action creators
Using the object syntax for mapDispatchToProps (mdtp), the nested
dashboardActions functions were not being properly bound to
dispatch, and lookuped to dashboardActions were failing. This
refactors that by de-nesting and spreading action creators directly
onto DashboardPage props.
2018-06-23 11:21:15 -07:00
Jared Scheib 31cd49e89f Refactor DashboardPage getDashboard & getDashboardsNames instance methods to assignment syntax 2018-06-22 18:46:28 -07:00
Jared Scheib 52eef4b206 Type setScrollTop instance method on DashboardPage 2018-06-22 18:45:56 -07:00
Jared Scheib a883d59960 Fix broken dashtimev1 delete dashboard test 2018-06-22 18:34:10 -07:00
Jared Scheib 04e8ebac0d Refactor app action types file structure & imports to new style 2018-06-22 18:26:15 -07:00
Jared Scheib a57055772a Refactor cellEditorOverlay types file structure & imports to new style 2018-06-22 18:22:49 -07:00
Jared Scheib 28b919908b Refactor notifications types file structure & imports to new style 2018-06-22 18:17:58 -07:00
Jared Scheib d74ad08c2c Fix dashboards.ts import in src/types/index.js 2018-06-22 18:14:21 -07:00
Jared Scheib 2626cf8955 Rename types/dashboard.ts to plural for consistency 2018-06-22 18:08:57 -07:00
Jared Scheib c7e46bbaee Rename types/actions/error.ts to plural for consistency 2018-06-22 18:07:29 -07:00
Jared Scheib 967bc8173a Rename types/reducers/dashboard.ts to plural for consistency 2018-06-22 18:06:26 -07:00
Jared Scheib 7d4332bb6f Rename types/actions/error.ts to errors.ts for consistency 2018-06-22 18:05:07 -07:00
Jared Scheib c11205199e Rename types/actions/dashboard.ts to dashboards.ts for consistency 2018-06-22 18:04:09 -07:00
Jared Scheib a0b2ee4aea Refactor annotations types file structure & imports to new style 2018-06-22 18:02:06 -07:00
Jared Scheib e23049946c Merge remote-tracking branch 'origin/master' into fun/dashboard_page 2018-06-22 17:53:44 -07:00
Delmer Reed 6135a4168f Stopgap-fix getDashboardsNamesThunk type error
Resolve react-redux type issues later to fix getDashboardsNames typing.

Co-authored-by: Jared Scheib <jared.scheib@gmail.com>
2018-06-22 20:43:46 -04:00
Delmer Reed 058af91e46 Refactor error types to follow new file structure
Co-authored-by: Jared Scheib <jared.scheib@gmail.com>
2018-06-22 20:42:00 -04:00
Alex Paxton 28cf67a142 Merge pull request #3704 from fntlnz/fix/main-template-body
Fix: Close main template body only once
2018-06-22 17:19:24 -07:00
Iris Scholten d3e0159aea Set y-axis scale default to linear 2018-06-22 17:02:18 -07:00
Iris Scholten 80ecabd036 Add 'None as an option for Base' 2018-06-22 16:56:41 -07:00
Delmer Reed 61130535e5 Update cell editor test to return null 2018-06-22 19:48:57 -04:00
Delmer Reed 8c2e8a2176 Add ErrorDescription with auth and links
ErrorThrownAction triggers an AUTH_EXPIRED in middleware. AuthReducer
extracts auth links to upddate state.links. It's unclear what the shape
is of auth.links:

  Errors.test.js utilizes an auth.links of type
    arrayOf({
      name: string,
      label:string,
      login: string,
      logout: string,
      callback: string,
    })

  OrganizationsPage consumes links w/ shape of

    shape({
      organizations: string.isRequired,
      config: shape({
        auth: string.isRequired,
      }).isRequired,
    })

  UsersPage consumes links w/ shape of

     shape({
        users: string.isRequired,
      }),

  ProvidersPage consumes links w/ shape of

    shape({
        organizations: string.isRequired,
      }),

  Purgatory consumes links w/ shape of

    shape({
      me: string,
    }),

  UserNavBlock at some point expected

  shape({
    me: string,
    external: shape({
      custom: arrayOf(
        shape({
          name: string.isRequired,
          url: string.isRequired,
        })
      ),
    }),
  })
2018-06-22 19:13:43 -04:00
Delmer Reed bbd66da6e2 Update ShowOverlayActionCreator import from overlayTechnoloy 2018-06-22 17:40:21 -04:00
Jared Scheib a49a4e7646 Refactor ManualRefresh interface to be consistent with withRouter
Clarifies relationship between HOCs and how to define DashboardPage
props by extending from the props it will receive from its HOCs.

Co-authored-by: Delmer Reed <delmer814+1@gmail.com>
2018-06-22 14:24:27 -07:00
Jared Scheib 9e8221e13b Compose DashboardPage prop types with withRouter & ManualRefresh
Co-authored-by: Delmer Reed <delmer814+1@gmail.com>
2018-06-22 14:07:57 -07:00
Jared Scheib 5e6f698db4 Convert ManualRefresh to TypeScript
Co-authored-by: Delmer Reed <delmer814+1@gmail.com>
2018-06-22 14:07:43 -07:00
Jared Scheib bcf88dd336 Rename ManualRefresh.js to ManualRefresh.tsx 2018-06-22 13:11:06 -07:00
Delmer Reed eb89268a2f Update hosts page optionsComponents to be a getter 2018-06-22 16:08:17 -04:00
Delmer Reed e3aaae62b4 Update title to titleText in Host and Admin page 2018-06-22 15:07:45 -04:00
Jared Scheib 3b111cc404 Type most of the rest of DashboardPage
Add stronger types to Dashboard Actions.

Refactor Dygraph.onZoom to pass TimeRange rather than splitting
arguments, and refactor respective DashboardPage & LogViewer
methods accordingly.
2018-06-21 20:42:10 -07:00
Chris Henn 4129cb2c4b Merge pull request #3749 from influxdata/bugfix/page-headers
Fix missing page titles
2018-06-21 19:33:37 -07:00
Delmer Reed 2ab002c280 Fix types for presentation mode dispatcher
Cleaned up dashboard types and introduced the auth reducers types.

Co-authored-by: Jared Scheib <jared.scheib@gmail.com>
2018-06-21 19:17:22 -04:00
Iris Scholten 184f9fd8c8 Merge pull request #3751 from influxdata/fix/crosshairs-pass-edge
Ensure hoverTime is a valid time range for the dygraph
2018-06-21 15:31:27 -07:00
Iris Scholten d3c41bdc4d Move check for valid time to first comparison 2018-06-21 14:59:37 -07:00
Iris Scholten 9e3e7d6565 Prevent index out of range error when getting min and max from timeRange 2018-06-21 14:58:28 -07:00
Iris Scholten 38e64be3af Ensure hoverTime is a valid time range for the dygraph 2018-06-21 13:43:11 -07:00
Christopher Henn 8e0b0280c7 Fix display of TemplateVariableEditor header 2018-06-21 11:38:14 -07:00
Christopher Henn 4356399967 Add test verifiying PageHeader dev assertion 2018-06-21 11:05:53 -07:00
Jared Scheib bb938c0bf9 Add & reorg types dirs and files for dashboard reducers, actions, & apis
Continue typing DashboardPage.
2018-06-21 11:03:28 -07:00
Christopher Henn 6d2e821e4a Fix failing admin page title test 2018-06-21 10:59:31 -07:00
Christopher Henn cb0fe600fd Add failing test for missing title on admin page 2018-06-21 10:59:31 -07:00
Christopher Henn ca4216240c Fix missing title on hosts page 2018-06-21 10:59:30 -07:00
Delmer 949151d0a2 Merge pull request #3745 from influxdata/flux/update-yields-on-script-change
Render data when yield node receives new script
2018-06-21 13:10:46 -04:00
Chris Henn 16c76d5c63 Merge pull request #3742 from influxdata/bugfix/flux-schema-formatting
Fix filter popup aesthetics
2018-06-21 09:59:13 -07:00
Chris Henn 803cfec5b8 Merge pull request #3738 from influxdata/tempVars/tests
Add two tests for template variables
2018-06-21 09:58:49 -07:00
Delmer Reed b35315eabb Clean up script update check 2018-06-21 12:46:58 -04:00
Delmer Reed 58854ec8f0 Render data when component recieves script update
Rendered yield data only currently happens on component mount and this
update checks for a script update to fetch yield results.
2018-06-21 12:19:17 -04:00
Delmer Reed 04c1601924 Update expressions to display yield in script
Updates expressions to pass a yield node from the script to a
YieldFuncNode and allowing the correct yield name to be displayed in the
builder.
2018-06-21 09:35:19 -04:00
Christopher Henn c4d4770cd6 Fix filter popup aesthetics 2018-06-20 16:55:50 -07:00
Jared Scheib 3b61fefefe Rename dashboards/apis/index.js to .ts 2018-06-20 16:28:13 -07:00
Jared Scheib 0fd89449bd Add & fix consumption of Dashboard ActionCreator types 2018-06-20 14:45:07 -07:00
Delmer Reed 280ea0732b Remove yield nodes not in declarations
Co-authored-by: Iris Scholten <ischolten.is@gmail.com>
2018-06-20 17:43:09 -04:00
Delmer Reed b33455e799 Move getDeep up and add space between types and relative imports 2018-06-20 17:33:13 -04:00
Jared Scheib 680c0e58f2 Merge remote-tracking branch 'origin/master' into fun/dashboard_page 2018-06-20 14:22:57 -07:00
Delmer Reed 754b119525 Fix FuncArgInput autofocusing
Keying by func.id instead of the func node's index was causing
the builder to repeatedly autofocus on the last expression node.

Co-authored-by: Alirie Gray <alirie.gray@gmail.com>
2018-06-20 17:19:56 -04:00
Jared Scheib c00c2f1a3a WIP 2018-06-20 14:15:39 -07:00
Jared Scheib 891397ffcd Simplify mapStateToProps & mapDispatchToProps 2018-06-20 13:57:12 -07:00
Delmer Reed c317e03e07 Delete yield node when func node is deleted
Deletes the func node and either toggles the yield with last or removes
the following yield from the script.

Co-authored-by: Alirie Gray <alirie.gray@gmail.com>
2018-06-20 16:55:52 -04:00
Christopher Henn d8a3332fe1 Add TemplateControlBar test 2018-06-20 12:48:20 -07:00
Christopher Henn 1bf264e373 Add TemplateControlDropdown test 2018-06-20 12:47:46 -07:00
Delmer 10af172b32 Merge pull request #3730 from influxdata/fix/script-yield-before-range-filter
Fix unable to toggle yields
2018-06-20 15:29:02 -04:00
Delmer Reed f591d72db2 Add type asserition to Papa.parse data
Parsed data from Papa.parse does not utilize a generic
type and returns any[]. Adding an asserition will at least
error if there are changes to the type of FluxTable.data.
2018-06-20 15:18:07 -04:00
Jared Scheib 46e9d305a3 Add type for GetAnnotationsAsync
Co-authored-by: Alirie Gray <alirie.gray@gmail.com>
2018-06-20 12:15:44 -07:00
Alex P dda369c24b Merge branch 'master' into presentational-page-components 2018-06-20 11:36:35 -07:00
Christopher Henn 438e0725bd Refactor TemplateControlBar test 2018-06-20 11:26:51 -07:00
Iris Scholten 3b3f4adf8c Return empty string if value is null 2018-06-20 11:13:38 -07:00
Alex P 11b712ee7f Rename prop to indicate intended use 2018-06-20 11:03:20 -07:00
Alex P 0d20a438d2 Improve clarity of prop name 2018-06-20 10:58:55 -07:00
Alex P 5753363168 Rename prop to be more descriptive 2018-06-20 10:57:19 -07:00
Alex P ed83a254b3 Use getters to pass in elements directly instead of functions that return elements 2018-06-20 10:54:49 -07:00
Alex P d2afd0f241 Fix rendering of logs toggle in TICKscript editor 2018-06-20 10:44:48 -07:00
Jared Scheib fad628f89f WIP Type DashboardPage & its dispatchers 2018-06-20 10:39:17 -07:00
Chris Henn c81658f938 Merge pull request #3734 from influxdata/tempVars/meta-queries
Add "Custom Meta Query" template variable type
2018-06-20 10:38:29 -07:00
Alex P 7b9abf9080 Rename prop to "RenderPageControls" 2018-06-20 10:38:23 -07:00
Alex P 8b147b78f7 Remove center render prop from PageHeader
Only one instance of use, not worth the added complexity
2018-06-20 10:37:57 -07:00
Christopher Henn b734f7cf00 Type MetaQueryTemplateBuilder constructor props 2018-06-20 10:03:18 -07:00
Christopher Henn 797b214d95 Access properties more safely 2018-06-20 10:02:33 -07:00
Delmer Reed 4e42fdcc35 Remove duplicate before/after filter and range checks
Removes component update checks for filter and range.
ExpressionNode now renders with a check for filter and range and
looks at the next func node index to determine how much script to pass
to YieldFuncNode. FuncNodes also utilize a isYielding and
isYieldingInScript to determine how to toggle yields.
2018-06-20 12:57:59 -04:00