* update to kea-typegen that runs through prettier
* remove posthog-js yalc package regression
* add types to toolbar
* add react-dom and react-redux types
* add types to toolbar react components
* convert a lot of components to typescript
* convert more components to typescript
* fix error
* actions return void
* clean up other Type.ts files as well
* fix last untyped files
* upgrade kea, fix webpack config entrypoint
* add stricter typechecking
* add types for a few more files
* fix bug with nth_child selectors (introduced in this PR, now fixed)
* fix one more type
* update to kea-typegen that runs through prettier
* update logic type files
* remove posthog-js yalc package regression
* upgrade to 0.0.32 that fixes error with string literals in defaults
* prettier wants to reformat things
* Add and configure isort
* isort all the things!
* Use local black and isort, and include json in prettier
* Remove erroneous import
* Delete isort.cfg and add isort options to lint-staged
* isort all the things! (with Black-compatibile options)
* working table
* add modal
* continue adding to modal
* added function to create global annotation
* format
* test commit
* add precommit
* add update function
* crud working
* add type
* fix tests
* add next
* add prompt
* tests
* fix tab alignment
* fix button float color
* default color in float mode
* long press extends the toolbar
* add new logo
* also add logo without text
* add window values plugin
* refactor utils
* support x,y coords in circle
* show toolbar button in new style
* remove float mode
* draging doesn't trigger click
* improve rotation
* improve heatmap number
* position of the close button
* "dock" icons to button
* clarify my choice
* show heatmap in a window
* show heatmap with a border
* use new icons
* open actions tab
* remove unused prop
* move Fade into lib/components
* animate with fire
* fix heatmap icon bug
* don't show X, new stats icon
* heatmap window title
* dock and close also shrink
* flag animation and loading for actions
* dock actions to button when enabled
* actions window
* open actions in button window
* colors for indicators
* close buttons
* inspect X
* add stats view with info
* new icons for close & dock
* add/edit actions in button mode
* color code the different elements in select element view
It did not run under `fish` shell at all, added a shebang to make it
work.
Also it assumed nodemon is installed globally. Instead we can add
nodemon as a devDependency and use `npx` to run it.
* WIP #517 feature flags
* Fix default filters
* Move decide to its own file
* Bump posthog-js 1.2.2
* Fix decide endpoint
* Add logic, update posthog-js
* yarn lock
* update snippet
* Add cypress tests
* Add example code
* Fix example code
* Add tests for query size
* Add errors when trying to create feature flag with same key
* Add explanation comment
* Fix cypress tests
* Do caching of teams in Team model
* Use <= instead of <
* Instrumentation and fix
* Fix ci test
* Add patch for team
* Debug test
* It passed
* Temporary Hack™ - allow access to the events API via the temporaryToken
* Consolidate small utility functions
* Heatmap [WIP]
* Let the mouse through
* adjust z-index
* no heatmap pointer events when inspecting
* bolder and more interactive toolbar button
* zoom and padding for float mode heatmap
* extend toolbar buttons from the mouse distance, add toggle for heatmap
* animated spinner when showing the heatmap
* add labels to circles
* fix distance bug
* more text shadow
* also highlight inspect element after something has been highlighted
* hover heatmap element
* highlight selected elements
* show metadata for heatmap
* reorder elements
* show inspect element box
* tiny "x" in magnifying glass
* close selected element metadata
* heatmap element click data
* add "add action" stub
* fix element selection logic ux inconsistencies, add esc support
* actionstep display
* move events around
* inspect element rect also via react
* extract element trim logic (path --> svg), add support for cursor:pointer click targets
* keep yellow markers in bounds, fix positions after a delay after scrolling
* get heatmap data from /api/element/stats/
* scale element metadata
* show ranking in metadata
* rename link to clickable
* remove posthog toolbar from clickable list
* move TemporaryTokenAuthentication to utils
* try to bust the cache
* use authentication screen to get temporaryToken, add toolbarLogic to store all props
* use button mode if not authenticated
* more control over animation
* can drag unauthenticated button
* hide heatmap when animating
* no need for cascading props
* call a width a width (radius was incorrect as it should be half that)
* clean toolbarButton code
* add 'userIntent' instead of 'defaultTab' to guide the user in adding an action
* enable heatmap in the float/dock toolbar
* re-request authentication on a 403
* small tweaks to scroll update delay and bust cache again
* double-space-cache-bust
* rotating text for logged out button
* split heatmap elements and labels into separate components
* heatmap with inspect element click targets
* also select all elements with cursor:pointer
* merge "inspectElement" and "heatmap" into "element", remove "inspect anything" mode
* fix element tooltip horizontal position
* escape class names in selector
* leave clues for the next time
* toolbar hello text update
* fix css escape issue on nth queries
* fix color in docusaurus v2 dark mode
* show element info window in sidebar in dock mode
* support ESC
* scrolling and animating won't conflict with each other in dock mode
* close button first unselects
* reverse elements if body is the last one returned
* click to select element in heatmap list
* only show element in toolbar in dock mode
* Order elements by order
* heatmap bottom position min and max heights
* keep window on screen
* remove element hack
* highlight element got stuck
* position heatmap info window better
* Fix tests
* remove selected element when disabling heatmap
* simple auth text
* 3 pixels lower
* center with flexbox
Co-authored-by: Tim Glaser <tim.glaser@hiberly.com>
* can zoom out toolbar
* refactor the look
* add kea localstorage plugin
* add test to see if user is logged in or not
* keep width when resizing window
* increase padding on larger screens
* floating box style
* toolbar close button
* show what's on the current page
* fix close and remove tags
* inspect element
* inspect element improvements
* show stats
* inspect element
* give jsURL to the editor in debug mode
* toolbar HMR
* move styles to CSS
* tabs on toolbar
* css for current page block
* links to dashboards and actions
* adjust the location of the X so that we don't always have a horizontal scrollbar
* clean up some css, incl renaming toolbar divs
* refactor webpack config to use a separate config for the editor chunk, in it include all CSS inside the JS
* load styles behind the shadow, render only once all CSS is loaded
* tolerable design for the floating view
* header block for float + css zindex fix
* fix height
* move toolbar to toolbar folder
* add back old toolbar folder
* load by default editor.js, move new toolbar to toolbar.js
* only open toolbar.js by default, not editor.js
* add comment for toolbar setting
* Updated Yarn lockfile
* fix test and rename is_authenticated -> isAuthenticated in json
* get mypy to play along
* refactor tab content into folders
* refactor code structure for toolbar
* simplify floating/docked/float/dock -> float/dock
* small refactor
* upgrade to posthog-js 1.1.0
* fix array copy code
* Closes #877 chunk loading errors
* Closes #877 chunk loading errors
* add chunks to all webpack files, use webpack-html-plugin to make an index.html with the right names
* change to contenthash for better caching
* add dev server on a different port
* store loaded scenes in reducer
* add react-hot-loader
* add react-hot-loader to all code split points
* fix action pages HMR
* ignore cypress screenshots
* generate django login/signup page layout with webpack html plugin
* move to devDependencies
* expose webpack-dev-server ports
* run tests on the production docker image
* start webpack dev server on a custom host if requested
* revert e2e to dev dockerfile
* add test travis config
* add stages
* add travis conf
* cache node and pip
* node 11
* travis ci bump
* node via nvm
* install v12, disable cypress for a moment
* remove 2 commands, test cached build time
* try different yarn cache, add cypress
* add postgres 12
* migrate before cypress
* remove latest postgres for now
* createdb before cypress
* Try different port
* cull packages
* remove hash from main bundle filenames to not break anything
* cypress port 8000
* cypress tests with production docker
* don't use the /code path in e2e test, use docker image
* remove hash from css to work better with editor
* only one export from actions
* remove travis test
Co-authored-by: Marius Andra <marius.andra@gmail.com>
* initial test
* add yaml
* add logs
* without tail
* run again for consistency
* wait longer
* manuall configure cypress
* use latest ubuntu
* try installing all
* yarn install
* yarn install with cypress
* full flow
* run again for consistency
* initial tests for trends
* handle exception
* separate e2e docker-compose
* run on pr
* trends-testing foundation
* run test
* don't pass everything
* handle uncaught exceptions
* fix dashboard tests
* change email domain
* change dataattr to data-attr and boilerplate cleanup
* base url config
* add script for test runner
* change default postgres
* more resize handles
* see-through loading overlay
* mobile mode, dragging dashboards, make panels wiggle, etc
* use long press and esc to control dragging
* clean up header
* disable dragging when clicking on the background
* clear toast on unmount, disable pointer events when dragging
* rearrange button
* clicking handles doesn't stop rearranging
* fix grid layout import
* fix header layout on mobile
* better alignment of version and worker info in responsive mode
* overflow fix
* pinned dashboards in sidebar
* more visible rearranging toast
* clear dom text selection after starting to resize panels
* add existing dahboard name in the "save to dashboard" modal
* add divider between pinned dashboards and the rest of the menu
* clarify how to exit drag mode
* dragging enabled by default, disabled if iOS or Android, long touch only to enable wobbly mode
* add margin under wobbly dragging mode to make it nicer to move the last item
* can drag panels from anywhere, except tables
* exclude tables from long pressing
* less padding in low resolutions
* Fix Error404
* resize and drag dashboard items
* fix funnel resize issues
* store layouts in kea
* layouts for different breakpoints
* save layouts after updating
* colors in submenu, but disabled
* save item colors
* 1920-sidebar breakpoint
* add graph colors for graphs with backgrounds
* pie chart label color and z-index to put over the chart if a long number
* create dashboard model
* add pinned dashboards to submenu
* rename "Default Dashboard" -> "Dashboard"
* refactor SaveToDashboard modal
* save onto right dashboard
* load and show dashboard data
* move logic to separate file
* dashboard selection
* prompt for name
* add promise cancellation for prompts, so that they close when we change the url
* show a global loading progress bar if it takes more than 500ms for any loader to work
* add dashboards on the dashboard page
* pin dashboards
* rename dashboard
* cut off text nicely in the sidebar
* delete dashboards
* dash item "more" link in antd style
* revert to ellipsis
* trigger by click, redirect well with delete
* remember last visited dash, update icons
* better view icons
* refactor Dashboard into subcomponents
* add a sad hedgehog for the 404 page
* fix loading keys
* add a few more overlay hedgehogs
* add new dashboard from "no dashboards" page
* use a hedgehog with a better license
* better redirect when deleting dashboard
* update dashboard items design
* dark sidebar
* make a few other scenes darker
* add a few styles that can be toggled
* add menu to change color of dashboard panel
* move to prompt logic
* new dashboard on dashboards page
* show success message in model
* refactor shared listeners
* rename dashboard item
* add new dashboard when adding to dashboards
* redirect after adding
* fix icon alignment
* undo deleting dashboards
* replace antd message with toast to close programmatically
* remove the style dropdown for now
* set the scene on a new "thread" to avoid react's reconciliation triggering logic building on the current run heap
* fix action run heap issue properly
* use table in dashboard list, link to all dashboards
* support links without hrefs
* empty dashboard style fix
* ignore type
* save created_by user
* remove nprogress spinner
* use antd table to render dashboards
* show "all dashboards" as the default when clicking the link
* pin dashboards automatically
* soft delete
* remove nprogress
* remove nprogress
* remove all caps
* export deleteWithUndo function
* add delete and pin links to dashboards list
* extract some components from EventsTable
* event table refactor
* move logic and load next events
* flip sort order
* eventSelected -> selectedEvent
* put all next fetching through the same fetchEvents action
* event polling
* onClick not needed
* refactor EventElements into separate file
* unique key for events table based on the view that is open
* disable filtering in actions page
* use <A> tag
* fix ===
* make property filter update the filter through the browser URL
* move from react-router to kea-router
* add root redirect
* fix dashboard urls
* remove <A /> tag, keep using <Link />
* load events before the scene opens
* rename ActionEvents -> LiveActions
* use eventsTableLogic for live actions
* when removing a filter, assure that there is a {} at the end
* save path so that we don't update anymore when we move off the page
* preload logic before scene
* better name for property filters
* fix default search input uncontrolled error
* set property filters through the url
* refactor some variable names
* clean active views and cached urls, add "order" to actions from url
* fix some linter errors
* build and pass logic
* turn actionFilterLogic into a controlled logic
* make it work
* small code improvements
* use properties from kea-router's search params
* upgrade kea-router
* use properties hash
* rename actionFilterLogic.js to entityFilterLogic.js and pass logic down in props
* more entityFilterLogic cleanup
* use new router for trends
* use objectsEqual instead of manual JSON.stringify comparison
* router.values.searchParams in propertyFilterLogic.js
* adding new entity type works
* always highlight something in the sidebar
* remove unused FilterLink.js
* refactor active submenu
* add query to link to /people
* funnels work again
* split property filters per id of funnel
* set $pageview or $screen as default action in /trends if just opening the URL, sparking loads of joy
* fix uncontrolled<->controlled input warning
* simpler loading, without breaking DOM rules
* cleaner loading screens
* fix uncontrolled to controlled warning
* do not show links to myself if showing events table under /person/:id
* uncontrolled - controlled input
* remove broken link to step event, fix duplicate key errors
* table loading as overlay if something in table
* show loading overlay only after 500ms
* undefined fix
* 2 more undefined fixes
* use kea-router's combineUrl instead of the homebrewn toParams()
* date filter returns dates as strings
* Closes #505 filter funnels by events as well as actions
* Simplify kea modules and store date_from directly against filter
* Use key on kea so the list doesn't get carried between funnels and trends
* Move filters to selector
* Remove useEffect
* Remove unused type: ignore
* Fix creating new funnel
* server/mypy: Enable no_implicit_optional
no_implicit_optional Changes the treatment of arguments with a default value of None by not implicitly making their type Optional.
Ref: https://mypy.readthedocs.io/en/stable/config_file.html#none-and-optional-handling
* server/mypy: Enable warn_unused_ignores
warn_unused_ignores: Warns about unneeded # type: ignore comments.
Ref: https://mypy.readthedocs.io/en/stable/config_file.html#configuring-warnings
It's best to exclude packages with no typing in mypy.ini rather than in
the code. This waym if tin the future these packages add types it's can
easily be disabled (by removing the exclusion in mypy.ini).
* api/user: Fix user password was not really validated
* api/test/base: Remove unreachable code
Team is created in setup, so no reason for it not to be there (unless
setUp is overriden by child, which as far as I can see is currently not
happening),
* server/mypy: Enable check_untyped_defs
check_untyped_defs: Type-checks the interior of functions without type annotations.
Ref: https://mypy.readthedocs.io/en/stable/config_file.html#untyped-definitions-and-calls
* server/mypy: Enable strict_equality
strict_equality: Prohibit equality checks, identity checks, and container checks between non-overlapping types.
Ref: https://mypy.readthedocs.io/en/stable/config_file.html#miscellaneous-strictness-flags
* server/mypy: Enable warn_unreachable
Added a fixme for a possible oversight in function that parses JSON.
warn_unreachable: Shows a warning when encountering any code
inferred to be unreachable or redundant after performing type
analysis.
Ref: https://mypy.readthedocs.io/en/stable/config_file.html#configuring-warnings
* api/posthog: fix possible bug when batch is not a list
Current code assumes batch is a valid list. If batch is not a list, the
capture handling will cause a 500 error.
* fix stricter mypy
* Use response.json instead of .data
Co-authored-by: Haki Benita <hakibenita@gmail.com>
* initial commit for dropin
* remove console log
* inner menu item weirdness
* recover original styling of modal and invite buttons
* colors and styling
* remove parent props
* updated path comparison and squashed an previous error on inviteteam modal
* returned some of previous implementation for less diff