* Move shared link form to modal
- As a preliminary step for enabling adding a pinned segment to a shared link, the functionality to add or edit a shared link is being moved to a modal.
- Minor UI improvements, such as update the style of the edit and delete buttons.
* Update tests
- Add shared_link_settings_test.exs for LiveView interactions (deletion, errors)
- Add shared_link_settings/form_test.exs for modal form testing (create, edit, validation)
- Update controller tests: remove deleted actions, update visibility test
* Update lib/plausible_web/components/generic.ex
Co-authored-by: Adrian Gruntkowski <adrian.gruntkowski@gmail.com>
* Update lib/plausible_web/components/generic.ex
Co-authored-by: Adrian Gruntkowski <adrian.gruntkowski@gmail.com>
* Refactor icon button components
* Fix spelling error
---------
Co-authored-by: Adrian Gruntkowski <adrian.gruntkowski@gmail.com>
* Enhance TypeScript definitions for Plausible tracking library
Updated the plausible.d.ts file to improve documentation by adding JSDoc comments for all functions and properties. This enhances clarity and usability for developers integrating the tracking library.
* Update CHANGELOG.md to reflect changes in TypeScript definition comments for improved IDE integration
* Format
* Remove subtitle from changelog
---------
Co-authored-by: Ahmed Hassanein <eng.a7mad.gamal@gmail.com>
* add opts to Check.perform signature
* increase domain change detection timeout to 11s
* same footer after submit + docs link
* domain change flow improvements
* fix for CE
* fix link
* rename to @plausible-analytics/tracker
* change icon
* Update site switcher UI to accommodate for consolidated view
* Implement logic to display consolidated view in site picker
* Fix "All sites" selected state in site switcher
* Fixup tests
* Include consolidated view assigns in shared links
* Format
* Extract `ConsolidatedView.ok_to_display?/2`
* Format
* I'll pretend no one saw this
* Skip unnecessary `on_ee`
* oops
---------
Co-authored-by: Adam Rutkowski <hq@mtod.org>
- Added dark mode change to CHANGELOG.md
- Fixed broken `WithImportedSwitch` icon focus outline
- Updated comments in `app.css` referencing old color scheme
* Improve dark mode
- Switch from `slate` to `zinc` for the gray color palette
- Darken overall dark mode UI
- Switch from `green` to `emerald` for the green color palette
- Update a few previously missed instances of title case to sentence case
- Consolidate button styles and change naming from `bright` to `secondary`
- Update button disabled styles
- Fix tooltip not adjusting to content width
- Update graph tooltip layout and typography
- Add transition effects to hover states
- Reduce footer logo size
* Fix oversights
- Update funnel graph colors
- Update graph grid colors
- Improve focus styles
- Improve disabled input styles
* Fix more oversights in relation to dashboard filtering
- Improve consistency of input, button, combobox and modal components in relation to settings area
- Fix segment tooltip color
* Fix search input style in funnel and segments dropdowns
* Add white background to favicon images in dark mode
- The GitHub and ChatGPT favicons are hard to see in dark mode, so we add a white background to them.
* Fix tooltip color to fit all backgrounds in dark mode
* Fix tests
* Fixed more tests
* Extract SourceFavicon component to eliminate favicon duplication
* Fix regression on installation page after rebase
* Fix formatting issues
* Fix favicon test failure in CI by reading placeholder icon at compile time
* Undo previous commit
* make timeout configurable for a check via check_opts
* add an internal_check_timeout test case to verification/checks_test.exs
* move verification observability tests to a separate file
... make it sync and test capturing Sentry events too
* separate detection observability checks too
* test sentry events in detection
* consider internal check timeouts browserless issues in detection too
* test util function defs to ee_only
* Display 24h charts in CRM
* Move New Custom Plan button to the top of the page
* Allow custom plan deletion
* Add managed proxy price modifier to custom plan estimation
* Broadcast tracker script config updates
* Fix broadcast_put typespec
* Preload site association on CE
* Stop preloading uselessly
* Reload tracker_script_config on CE only
* add module name to service_error when check times out
Otherwise, it can sometimes remain unclear in the diagnostics, whether
it was InstallationV2 or InstallationV2CacheBust that timed out.
* Remove duplicate timeout logic
The current production logs show two types of verification timeouts:
* service_error: "Unhandled Browserless response status: 408" (vast
majority of cases)
* service_error: :timeout (only a few cases)
The latter happens when we hit the Req receive_timeout
(endpoint_timeout + 2s). I've seen Browserless not respect the timeout
param from time to time, so it's better to keep the timeout logic
"in-house" only.
* make service_error into a map with code and extra
* interpret temporary service errors
...but still consider them "unhandled" for telemetry, also notifying Sentry
and logging the warning.
* separate sentry messages (verification)
* make Verification.ChecksTest more DRY
* organize tests into describe blocks
* test verification telemetry and logging
* fix codespell
* get rid of legacy verification
* rename Checks.InstallationV2 -> Checks.VerifyInstallation
* delete Live.Installation and rename Live.InstallationV2 -> Live.Installation
* rename installationv2 (live) files as well
* delete old change-domain routes
Also rename current liveview modules and routes, removing the v2 suffix
* rename domain_change_v2 files, removing v2 suffix
* remove legacy JS verifier code
Also fix dockerignore and elixir.yml referencing a wrong priv path
* rename verification_v2_test -> verification_test
* remove v2 prefix from logs and sentry messages
* clean up duplicate external_sites_controller_test.exs tests
* remove flag
* fix typespec
* pass timeout as query param to Browserless too
* Fixup external sites controller test module (#5826)
* fix test description
* clean up detection sentry events + tests
* improve naming
---------
Co-authored-by: Artur Pata <artur.pata@gmail.com>
* add module name to service_error when check times out
Otherwise, it can sometimes remain unclear in the diagnostics, whether
it was InstallationV2 or InstallationV2CacheBust that timed out.
* Remove duplicate timeout logic
The current production logs show two types of verification timeouts:
* service_error: "Unhandled Browserless response status: 408" (vast
majority of cases)
* service_error: :timeout (only a few cases)
The latter happens when we hit the Req receive_timeout
(endpoint_timeout + 2s). I've seen Browserless not respect the timeout
param from time to time, so it's better to keep the timeout logic
"in-house" only.
* make service_error into a map with code and extra
* interpret temporary service errors
...but still consider them "unhandled" for telemetry, also notifying Sentry
and logging the warning.
* separate sentry messages (verification)
* make Verification.ChecksTest more DRY
* organize tests into describe blocks
* test verification telemetry and logging
* fix codespell
* get rid of legacy verification
* rename Checks.InstallationV2 -> Checks.VerifyInstallation
* delete Live.Installation and rename Live.InstallationV2 -> Live.Installation
* rename installationv2 (live) files as well
* delete old change-domain routes
Also rename current liveview modules and routes, removing the v2 suffix
* rename domain_change_v2 files, removing v2 suffix
* remove legacy JS verifier code
Also fix dockerignore and elixir.yml referencing a wrong priv path
* rename verification_v2_test -> verification_test
* remove v2 prefix from logs and sentry messages
* clean up duplicate external_sites_controller_test.exs tests
* remove flag
* fix typespec
* pass timeout as query param to Browserless too
* Fixup external sites controller test module (#5826)
* fix test description
---------
Co-authored-by: Artur Pata <artur.pata@gmail.com>
* add module name to service_error when check times out
Otherwise, it can sometimes remain unclear in the diagnostics, whether
it was InstallationV2 or InstallationV2CacheBust that timed out.
* Remove duplicate timeout logic
The current production logs show two types of verification timeouts:
* service_error: "Unhandled Browserless response status: 408" (vast
majority of cases)
* service_error: :timeout (only a few cases)
The latter happens when we hit the Req receive_timeout
(endpoint_timeout + 2s). I've seen Browserless not respect the timeout
param from time to time, so it's better to keep the timeout logic
"in-house" only.
* make service_error into a map with code and extra
* interpret temporary service errors
...but still consider them "unhandled" for telemetry, also notifying Sentry
and logging the warning.
* separate sentry messages (verification)
* make Verification.ChecksTest more DRY
* organize tests into describe blocks
* test verification telemetry and logging
* fix codespell
* pass timeout as query param to Browserless too
* Add tests for query timezones
* Test timezones at controller level
* Remove v1 controller tests for ambigous times
* Add tests for legacy_time_on_page_cutoff
* Add test for generic cutoff timezone behaviour without gaps
* Create static consolidated view UI on `/sites` page
- Improve existing site card layout
- Add static UI for the consolidated view
- Add dismissable upgrade card UI
- Extract favicon fetching logic to function
- Configure configurable fallback icon per route
- Add `/favicon/sources_globe/` route with different icon than `/favicon/sources/` to use on `/sites` page
* Improve the mobile view of the `/sites` page
* Minor query interface UX extension (#5713)
* Minor query interface extension
* !fixup
* !fixup
* Initial implementation of consolidated views on /sites
* Improve loading state
* no need to handle nil in main interface
* Juggle `can_manage_consolidated_view?`
* Require team setup in order to enable consolidated view
* nil catcher
* Fixup test fixture
* Don't show Consolidated View tab in CS if team is not setup
* Reorganize + test
* Remove comment
* Only show consolidated views to superadmins for now
* Remove temporary sleep
* CE unused bindings
* Clean up seeds
* EE
* Fixup test
* Test non-superadmin scenario
* Add a test guarding parity between small plots (consolidated vs individual)
* Move private function so CE won't complain
* See if the graphs are now similar at least :)
* sort
* Map keys are unsorted
* Ensure engagement events aren't counted as visitors on smol graphs
* just try and revert
* Revert "just try and revert"
This reverts commit 7584f59816.
* Simplify globe icon handling
* Remove unnecessary @rest
* Split tests into more focused cases
* Address jumpiness on furious refresh cycle
* Revert "Address jumpiness on furious refresh cycle"
This reverts commit 5c03b36918.
* Another attempt at jumpiness
* Enforce less noticeable lag applying the diff from loading to loaded
* Reduce flashing on stats load
---------
Co-authored-by: Sanne de Vries <sannedv@protonmail.com>
* Ensure `conn` from `Plug.Conn.read_body` is always passed down the pipeline
* Alter persistor related histogram metrics for better view of timings
* Update typespec
* Start passing official installs that are using legacy .compat installation
* Pass the first domain for verifying legacy compat installs
* Fix variable access issue
* Fix non-existent function call
* Comment why split domainString
* do not use cache bust url in initial installaton check
* make installation_v2_cache_bust replace diagnostics, not add them
The test added in this commit also surfaced the function clause error
encountered on prod. This is also fixed in this commit by making sure
delays are given to Req retries as integers, rather than floats.
* assert_matches