Skip to content

Commit f43a067

Browse files
authored
Merge branch 'master' into guest-permissions
2 parents e8185e5 + b551997 commit f43a067

File tree

12 files changed

+71
-42
lines changed

12 files changed

+71
-42
lines changed

.github/workflows/elixir.yml

Lines changed: 3 additions & 17 deletions
Original file line numberDiff line numberDiff line change
@@ -20,24 +20,10 @@ jobs:
2020
runs-on: ubuntu-latest
2121
strategy:
2222
matrix:
23-
mix_env: ["test"]
24-
postgres_image: ["postgres:15"]
23+
mix_env: ["test", "ce_test"]
24+
postgres_image: ["postgres:18"]
2525
mix_test_partition: [1, 2, 3, 4, 5, 6]
2626

27-
include:
28-
- mix_env: "ce_test"
29-
postgres_image: "postgres:16"
30-
mix_test_partition: 1
31-
- mix_env: "ce_test"
32-
postgres_image: "postgres:16"
33-
mix_test_partition: 2
34-
- mix_env: "ce_test"
35-
postgres_image: "postgres:16"
36-
mix_test_partition: 3
37-
- mix_env: "ce_test"
38-
postgres_image: "postgres:16"
39-
mix_test_partition: 4
40-
4127
env:
4228
MIX_ENV: ${{ matrix.mix_env }}
4329
services:
@@ -128,7 +114,7 @@ jobs:
128114
129115
130116
- run: |
131-
mix test --include slow --include migrations --max-failures 1 --warnings-as-errors --partitions 4 | tee test_output.log
117+
mix test --include slow --include migrations --max-failures 1 --warnings-as-errors --partitions 6 | tee test_output.log
132118
if grep -E '\.+[0-9]{2}:[0-9]{2}:[0-9]{2}\.[0-9]{3} \[[^]]+\]' test_output.log | grep -v 'libcluster'; then
133119
echo "The tests are producing output, this usually indicates some error"
134120
exit 1

CHANGELOG.md

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -14,6 +14,7 @@ All notable changes to this project will be documented in this file.
1414
### Changed
1515

1616
- Segment filters are visible to anyone who can view the dashboard with that segment applied, including personal segments on public dashboards
17+
- Keybind hints are hidden on smaller screens
1718

1819
### Fixed
1920

Makefile

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -44,7 +44,7 @@ postgres-client: ## Connect to postgres
4444
docker exec -it plausible_db psql -U postgres -d plausible_dev
4545

4646
postgres-prod: ## Start a container with the same version of postgres as the one in prod
47-
docker run $(PG_FLAGS) --volume=plausible_db_prod:/var/lib/postgresql/data postgres:15
47+
docker run $(PG_FLAGS) --volume=plausible_db_prod:/var/lib/postgresql/data postgres:18
4848

4949
postgres-stop: ## Stop and remove the postgres container
5050
docker stop plausible_db && docker rm plausible_db

assets/js/dashboard/components/search-input.tsx

Lines changed: 21 additions & 16 deletions
Original file line numberDiff line numberDiff line change
@@ -12,14 +12,14 @@ export const SearchInput = ({
1212
searchRef,
1313
onSearch,
1414
className,
15-
placeholderFocused = 'Search',
16-
placeholderUnfocused = 'Press / to search'
15+
placeholderFocusedOrMobile = 'Search',
16+
placeholderUnfocusedOnlyDesktop = 'Press / to search'
1717
}: {
1818
searchRef: RefObject<HTMLInputElement>
1919
onSearch: (value: string) => void
2020
className?: string
21-
placeholderFocused?: string
22-
placeholderUnfocused?: string
21+
placeholderFocusedOrMobile?: string
22+
placeholderUnfocusedOnlyDesktop?: string
2323
}) => {
2424
const [isFocused, setIsFocused] = useState(false)
2525

@@ -59,18 +59,23 @@ export const SearchInput = ({
5959
shouldIgnoreWhen={[isModifierPressed, () => isFocused]}
6060
targetRef="document"
6161
/>
62-
<input
63-
onBlur={() => setIsFocused(false)}
64-
onFocus={() => setIsFocused(true)}
65-
ref={searchRef}
66-
type="text"
67-
placeholder={isFocused ? placeholderFocused : placeholderUnfocused}
68-
className={classNames(
69-
'text-sm dark:text-gray-100 block border-gray-300 dark:border-gray-750 rounded-md dark:bg-gray-750 max-w-64 w-full dark:placeholder:text-gray-400 focus:outline-none focus:ring-3 focus:ring-indigo-500/20 dark:focus:ring-indigo-500/25 focus:border-indigo-500',
70-
className
71-
)}
72-
onChange={debouncedOnSearchInputChange}
73-
/>
62+
<div className={classNames('relative max-w-64 w-full', className)}>
63+
<input
64+
onBlur={() => setIsFocused(false)}
65+
onFocus={() => setIsFocused(true)}
66+
ref={searchRef}
67+
type="text"
68+
placeholder=" "
69+
className="peer w-full text-sm dark:text-gray-100 block border-gray-300 dark:border-gray-750 rounded-md dark:bg-gray-750 dark:placeholder:text-gray-400 focus:outline-none focus:ring-3 focus:ring-indigo-500/20 dark:focus:ring-indigo-500/25 focus:border-indigo-500"
70+
onChange={debouncedOnSearchInputChange}
71+
/>
72+
<span className="pointer-events-none absolute left-3 top-1/2 -translate-y-1/2 text-sm text-gray-400 dark:text-gray-400 peer-[:not(:placeholder-shown)]:hidden md:peer-[:not(:focus)]:hidden">
73+
{placeholderFocusedOrMobile}
74+
</span>
75+
<span className="pointer-events-none absolute left-3 top-1/2 -translate-y-1/2 text-sm text-gray-400 dark:text-gray-400 peer-[:not(:placeholder-shown)]:hidden hidden md:peer-[:not(:focus)]:block peer-focus:hidden">
76+
{placeholderUnfocusedOnlyDesktop}
77+
</span>
78+
</div>
7479
</>
7580
)
7681
}

assets/js/dashboard/components/tabs.tsx

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -174,8 +174,7 @@ const Items = ({ options, searchable, closeDropdown }: ItemsProps) => {
174174
<div className="flex items-center p-1">
175175
<SearchInput
176176
searchRef={searchRef}
177-
placeholderUnfocused="Press / to search"
178-
className="w-full !max-w-none"
177+
className="!max-w-none"
179178
onSearch={handleSearchInput}
180179
/>
181180
</div>

assets/js/dashboard/keybinding.tsx

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -145,7 +145,7 @@ export function KeybindHint({
145145
return (
146146
<kbd
147147
className={classNames(
148-
'rounded bg-white dark:bg-gray-800 border border-gray-200 dark:border-gray-600 px-1.5 font-medium text-xs text-gray-400',
148+
'hidden md:block rounded bg-white dark:bg-gray-800 border border-gray-200 dark:border-gray-600 px-1.5 font-medium text-xs text-gray-400',
149149
className
150150
)}
151151
>

assets/js/dashboard/nav-menu/segments/searchable-segments-section.tsx

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -81,8 +81,7 @@ export const SearchableSegmentsSection = ({
8181
{showSearch && (
8282
<SearchInput
8383
searchRef={searchRef}
84-
placeholderUnfocused="Press / to search"
85-
className="ml-auto w-full py-1"
84+
className="ml-auto py-1"
8685
onSearch={handleSearchInput}
8786
/>
8887
)}

assets/js/dashboard/stats/behaviours/index.js

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -572,7 +572,9 @@ export default function Behaviours({ importedDataInView }) {
572572
{isRealtime() && <Pill className="-mt-1">last 30min</Pill>}
573573
{renderImportedQueryUnsupportedWarning()}
574574
</div>
575-
<MoreLink state={moreLinkState} linkProps={moreLinkProps()} />
575+
{mode !== FUNNELS && (
576+
<MoreLink state={moreLinkState} linkProps={moreLinkProps()} />
577+
)}
576578
</ReportHeader>
577579
{renderContent()}
578580
</ReportLayout>

assets/js/dashboard/stats/modals/breakdown-table.tsx

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -56,7 +56,9 @@ export const BreakdownTable = <TListItem extends { name: string }>({
5656
searchRef={searchRef}
5757
onSearch={onSearch}
5858
className={
59-
displayError && status === 'error' ? 'pointer-events-none' : ''
59+
displayError && status === 'error'
60+
? '[&_input]:pointer-events-none'
61+
: ''
6062
}
6163
/>
6264
)}

assets/js/dashboard/util/tooltip.tsx

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -91,7 +91,7 @@ function TooltipMessage({
9191
ref={setPopperElement}
9292
style={popperStyle}
9393
{...popperAttributes}
94-
className="z-[99] px-2 py-1 rounded-sm text-sm text-gray-100 font-medium bg-gray-800 dark:bg-gray-700"
94+
className="z-[99] [body:has(.modal.is-open)_&]:z-[1000] px-2 py-1 rounded-sm text-sm text-gray-100 font-medium bg-gray-800 dark:bg-gray-700"
9595
role="tooltip"
9696
>
9797
{children}

0 commit comments

Comments
 (0)