Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
6 changes: 2 additions & 4 deletions frontend/__tests__/components/ui/form/InputField.spec.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -83,12 +83,10 @@ describe("InputField", () => {
expect(screen.getByRole("textbox")).toBeDisabled();
});

it("shows FieldIndicator when showIndicator is true", () => {
it("shows FieldIndicator", () => {
const field = makeField("name");
field.state.meta.isValidating = true;
const { container } = render(() => (
<InputField field={() => field} showIndicator />
));
const { container } = render(() => <InputField field={() => field} />);

expect(container.querySelector(".fa-circle-notch")).toBeInTheDocument();
});
Expand Down
10 changes: 10 additions & 0 deletions frontend/src/html/pages/settings.html
Original file line number Diff line number Diff line change
Expand Up @@ -712,6 +712,16 @@
<button data-config-value="14">fist fight</button>
<button data-config-value="15">rubber keys</button>
<button data-config-value="16">fart</button>
<button data-config-value="17">akko lavenders</button>
<button data-config-value="18">cherrymx black abs</button>
<button data-config-value="19">cherrymx black pbt</button>
<button data-config-value="20">cherrymx blue abs</button>
<button data-config-value="21">cherrymx blue pbt</button>
<button data-config-value="22">cherrymx brown pbt</button>
<button data-config-value="23">kalih box white</button>
<button data-config-value="24">razer green</button>
<button data-config-value="25">tealios v2</button>
<button data-config-value="26">trust gxt</button>
</div>
</div>
<div class="section fullWidth" data-config-name="playSoundOnError">
Expand Down
81 changes: 71 additions & 10 deletions frontend/src/ts/collections/results.ts
Original file line number Diff line number Diff line change
Expand Up @@ -26,9 +26,14 @@ import Ape from "../ape";
import { SnapshotResult } from "../constants/default-snapshot";
import { queryClient } from "../queries";
import { baseKey } from "../queries/utils/keys";
import { __nonReactive as tagsNonReactive, updateLocalTagPB } from "./tags";
import {
__nonReactive as tagsNonReactive,
reconcileLocalTagPB,
saveLocalTagPB,
} from "./tags";
import { isAuthenticated } from "../states/core";
import { createEffectOn } from "../hooks/effects";
import { getLastResult, setLastResult } from "../states/snapshot";

export type ResultsQueryState = {
difficulty: SnapshotResult<Mode>["difficulty"][];
Expand Down Expand Up @@ -224,9 +229,18 @@ const resultsCollection = createCollection(
throw new Error("Error fetching results:" + response.body.message);
}

return response.body.data.map((result) =>
const results = response.body.data.map((result) =>
normalizeResult(result, knownTagIds),
);

if (getLastResult() === undefined && results.length > 0) {
const lastResult = results.reduce((acc, cur) =>
acc === undefined || acc.timestamp < cur.timestamp ? cur : acc,
);
setLastResult(lastResult);
}

return results;
},
queryClient,
getKey: (it) => it._id,
Expand Down Expand Up @@ -278,7 +292,7 @@ const actions = {
...newTagIds.filter((tag) => !currentTagIds.includes(tag)),
];
tagsToUpdate.forEach((tag) => {
updateLocalTagPB(
reconcileLocalTagPB(
tag,
result.mode,
result.mode2,
Expand Down Expand Up @@ -312,6 +326,49 @@ const actions = {
export async function updateTags(
params: ActionType["updateTags"],
): Promise<void> {
if (!resultsCollection.isReady()) {
// if its not ready yet, send the api request to update the tags
const response = await Ape.results.updateTags({
body: { resultId: params.resultId, tagIds: params.newTagIds },
});

if (response.status !== 200) {
throw new Error(`Failed to update result tag: ${response.body.message}`);
}

const result = getLastResult();

if (result === undefined) {
throw new Error(`Cannot find result with id ${params.resultId}`);
}

if (result._id !== params.resultId) {
throw new Error(
`Last result id ${result._id} does not match updated result id ${params.resultId}. Call the devs and tell them to fix their ugly code`,
);
}

response.body.data.tagPbs.forEach((tag) => {
saveLocalTagPB(
tag,
result.mode,
result.mode2,
result.punctuation,
result.numbers,
result.language,
result.difficulty,
result.lazyMode,
result.wpm,
result.acc,
result.rawWpm,
result.consistency,
);
});

params.afterUpdate?.({ tagPbs: response.body.data.tagPbs });
return;
}

const transaction = actions.updateTags(params);
await transaction.isPersisted.promise;
}
Expand Down Expand Up @@ -500,13 +557,17 @@ export async function getUserAverage10(
//exit early if there is no user. Don't init the result collection
if (!isAuthenticated()) return { wpm: 0, acc: 0 };

const result = await queryOnce(() =>
buildSettingsResultsQuery(options, {
tagIds: tagsNonReactive.getActiveTags().map((it) => it._id),
})
.orderBy(({ r }) => r.timestamp, "desc")
.limit(10)
.select(({ r }) => ({ wpm: avg(r.wpm), acc: avg(r.acc) })),
const result = await queryOnce((q) =>
q
.from({
//we use sub-query to filter first and then aggregate
last10: buildSettingsResultsQuery(options, {
tagIds: tagsNonReactive.getActiveTags().map((it) => it._id),
})
.orderBy(({ r }) => r.timestamp, "desc")
.limit(10),
})
.select(({ last10 }) => ({ wpm: avg(last10.wpm), acc: avg(last10.acc) })),
);

return result.length === 1 && result[0] !== undefined
Expand Down
2 changes: 1 addition & 1 deletion frontend/src/ts/collections/tags.ts
Original file line number Diff line number Diff line change
Expand Up @@ -396,7 +396,7 @@ export function saveLocalTagPB<M extends Mode>(
tagsCollection.utils.writeUpdate(tag);
}

export function updateLocalTagPB<M extends Mode>(
export function reconcileLocalTagPB<M extends Mode>(
tagId: string,
mode: M,
mode2: Mode2<M>,
Expand Down
10 changes: 10 additions & 0 deletions frontend/src/ts/commandline/commandline-metadata.ts
Original file line number Diff line number Diff line change
Expand Up @@ -393,6 +393,16 @@ export const commandlineConfigMetadata: CommandlineConfigMetadataObject = {
"14": "fist fight",
"15": "rubber keys",
"16": "fart",
"17": "akko lavenders",
"18": "cherrymx black abs",
"19": "cherrymx black pbt",
"20": "cherrymx blue abs",
"21": "cherrymx blue pbt",
"22": "cherrymx brown pbt",
"23": "kalih box white",
"24": "razer green",
"25": "tealios v2",
"26": "trust gxt",
};
return map[value];
},
Expand Down
5 changes: 0 additions & 5 deletions frontend/src/ts/components/pages/login/Register.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -166,7 +166,6 @@ export function Register(): JSXElement {
<InputField
field={field}
placeholder="username"
showIndicator
autocomplete="new-username"
disabled={!getLoginPageInputsEnabled()}
/>
Expand All @@ -187,7 +186,6 @@ export function Register(): JSXElement {
<InputField
field={field}
placeholder="email"
showIndicator
autocomplete="new-email"
disabled={!getLoginPageInputsEnabled()}
onFocus={() => {
Expand All @@ -214,7 +212,6 @@ export function Register(): JSXElement {
children={(field) => (
<InputField
field={field}
showIndicator
autocomplete="verify-email"
placeholder="verify email"
disabled={!getLoginPageInputsEnabled()}
Expand All @@ -238,7 +235,6 @@ export function Register(): JSXElement {
<InputField
field={field}
placeholder="password"
showIndicator
autocomplete="new-password"
type="password"
disabled={!getLoginPageInputsEnabled()}
Expand All @@ -256,7 +252,6 @@ export function Register(): JSXElement {
children={(field) => (
<InputField
field={field}
showIndicator
placeholder="verify password"
autocomplete="verify-password"
type="password"
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -86,7 +86,6 @@ export function ProfileSearchPage(): JSXElement {
<InputField
field={field}
placeholder="username"
showIndicator
autocomplete="new-username"
disabled={!isEditable()}
/>
Expand Down
5 changes: 2 additions & 3 deletions frontend/src/ts/components/ui/form/InputField.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,6 @@
export function InputField(props: {
field: Accessor<AnyFieldApi>;
placeholder?: string;
showIndicator?: boolean;
autocomplete?: string;
type?: string;
disabled?: boolean;
Expand All @@ -24,7 +23,7 @@
"rounded border-none bg-sub-alt p-[0.5em] text-em-base leading-[1.25em] caret-main outline-none",
"focus-visible:shadow-[0_0_0_0.1rem_var(--bg-color),0_0_0_0.2rem_var(--text-color)]",
"autofill-fix",
props.showIndicator === true ? "pr-[1.85em]" : "",
props.field().options.validators ? "pr-[1.85em]" : "",
props.class,
)}
type={props.type ?? "text"}
Expand All @@ -40,7 +39,7 @@
dir={props.dir}
maxLength={props.maxLength}
/>
<Show when={props.showIndicator}>
<Show when={props.field().options.validators}>

Check failure on line 42 in frontend/src/ts/components/ui/form/InputField.tsx

View workflow job for this annotation

GitHub Actions / ci-fe

[jsx] __tests__/components/ui/form/InputField.spec.tsx > InputField > hides FieldIndicator by default

TypeError: Cannot read properties of undefined (reading 'validators') ❯ Object.get when [as when] src/ts/components/ui/form/InputField.tsx:42:33 ❯ Object.Show.createMemo.name [as fn] ../node_modules/.pnpm/solid-js@1.9.10/node_modules/solid-js/dist/dev.js:1521:49 ❯ runComputation ../node_modules/.pnpm/solid-js@1.9.10/node_modules/solid-js/dist/dev.js:742:22 ❯ updateComputation ../node_modules/.pnpm/solid-js@1.9.10/node_modules/solid-js/dist/dev.js:724:3 ❯ createMemo ../node_modules/.pnpm/solid-js@1.9.10/node_modules/solid-js/dist/dev.js:273:10 ❯ Show ../node_modules/.pnpm/solid-js@1.9.10/node_modules/solid-js/dist/dev.js:1521:26 ❯ ../node_modules/.pnpm/solid-js@1.9.10/node_modules/solid-js/dist/dev.js:586:12 ❯ untrack ../node_modules/.pnpm/solid-js@1.9.10/node_modules/solid-js/dist/dev.js:475:12 ❯ Object.fn ../node_modules/.pnpm/solid-js@1.9.10/node_modules/solid-js/dist/dev.js:582:37 ❯ runComputation ../node_modules/.pnpm/solid-js@1.9.10/node_modules/solid-js/dist/dev.js:742:22

Check failure on line 42 in frontend/src/ts/components/ui/form/InputField.tsx

View workflow job for this annotation

GitHub Actions / ci-fe

[jsx] __tests__/components/ui/form/InputField.spec.tsx > InputField > shows FieldIndicator

TypeError: Cannot read properties of undefined (reading 'validators') ❯ Object.get when [as when] src/ts/components/ui/form/InputField.tsx:42:33 ❯ Object.Show.createMemo.name [as fn] ../node_modules/.pnpm/solid-js@1.9.10/node_modules/solid-js/dist/dev.js:1521:49 ❯ runComputation ../node_modules/.pnpm/solid-js@1.9.10/node_modules/solid-js/dist/dev.js:742:22 ❯ updateComputation ../node_modules/.pnpm/solid-js@1.9.10/node_modules/solid-js/dist/dev.js:724:3 ❯ createMemo ../node_modules/.pnpm/solid-js@1.9.10/node_modules/solid-js/dist/dev.js:273:10 ❯ Show ../node_modules/.pnpm/solid-js@1.9.10/node_modules/solid-js/dist/dev.js:1521:26 ❯ ../node_modules/.pnpm/solid-js@1.9.10/node_modules/solid-js/dist/dev.js:586:12 ❯ untrack ../node_modules/.pnpm/solid-js@1.9.10/node_modules/solid-js/dist/dev.js:475:12 ❯ Object.fn ../node_modules/.pnpm/solid-js@1.9.10/node_modules/solid-js/dist/dev.js:582:37 ❯ runComputation ../node_modules/.pnpm/solid-js@1.9.10/node_modules/solid-js/dist/dev.js:742:22

Check failure on line 42 in frontend/src/ts/components/ui/form/InputField.tsx

View workflow job for this annotation

GitHub Actions / ci-fe

[jsx] __tests__/components/ui/form/InputField.spec.tsx > InputField > renders disabled input

TypeError: Cannot read properties of undefined (reading 'validators') ❯ Object.get when [as when] src/ts/components/ui/form/InputField.tsx:42:33 ❯ Object.Show.createMemo.name [as fn] ../node_modules/.pnpm/solid-js@1.9.10/node_modules/solid-js/dist/dev.js:1521:49 ❯ runComputation ../node_modules/.pnpm/solid-js@1.9.10/node_modules/solid-js/dist/dev.js:742:22 ❯ updateComputation ../node_modules/.pnpm/solid-js@1.9.10/node_modules/solid-js/dist/dev.js:724:3 ❯ createMemo ../node_modules/.pnpm/solid-js@1.9.10/node_modules/solid-js/dist/dev.js:273:10 ❯ Show ../node_modules/.pnpm/solid-js@1.9.10/node_modules/solid-js/dist/dev.js:1521:26 ❯ ../node_modules/.pnpm/solid-js@1.9.10/node_modules/solid-js/dist/dev.js:586:12 ❯ untrack ../node_modules/.pnpm/solid-js@1.9.10/node_modules/solid-js/dist/dev.js:475:12 ❯ Object.fn ../node_modules/.pnpm/solid-js@1.9.10/node_modules/solid-js/dist/dev.js:582:37 ❯ runComputation ../node_modules/.pnpm/solid-js@1.9.10/node_modules/solid-js/dist/dev.js:742:22

Check failure on line 42 in frontend/src/ts/components/ui/form/InputField.tsx

View workflow job for this annotation

GitHub Actions / ci-fe

[jsx] __tests__/components/ui/form/InputField.spec.tsx > InputField > calls onFocus callback

TypeError: Cannot read properties of undefined (reading 'validators') ❯ Object.get when [as when] src/ts/components/ui/form/InputField.tsx:42:33 ❯ Object.Show.createMemo.name [as fn] ../node_modules/.pnpm/solid-js@1.9.10/node_modules/solid-js/dist/dev.js:1521:49 ❯ runComputation ../node_modules/.pnpm/solid-js@1.9.10/node_modules/solid-js/dist/dev.js:742:22 ❯ updateComputation ../node_modules/.pnpm/solid-js@1.9.10/node_modules/solid-js/dist/dev.js:724:3 ❯ createMemo ../node_modules/.pnpm/solid-js@1.9.10/node_modules/solid-js/dist/dev.js:273:10 ❯ Show ../node_modules/.pnpm/solid-js@1.9.10/node_modules/solid-js/dist/dev.js:1521:26 ❯ ../node_modules/.pnpm/solid-js@1.9.10/node_modules/solid-js/dist/dev.js:586:12 ❯ untrack ../node_modules/.pnpm/solid-js@1.9.10/node_modules/solid-js/dist/dev.js:475:12 ❯ Object.fn ../node_modules/.pnpm/solid-js@1.9.10/node_modules/solid-js/dist/dev.js:582:37 ❯ runComputation ../node_modules/.pnpm/solid-js@1.9.10/node_modules/solid-js/dist/dev.js:742:22

Check failure on line 42 in frontend/src/ts/components/ui/form/InputField.tsx

View workflow job for this annotation

GitHub Actions / ci-fe

[jsx] __tests__/components/ui/form/InputField.spec.tsx > InputField > calls handleBlur on blur

TypeError: Cannot read properties of undefined (reading 'validators') ❯ Object.get when [as when] src/ts/components/ui/form/InputField.tsx:42:33 ❯ Object.Show.createMemo.name [as fn] ../node_modules/.pnpm/solid-js@1.9.10/node_modules/solid-js/dist/dev.js:1521:49 ❯ runComputation ../node_modules/.pnpm/solid-js@1.9.10/node_modules/solid-js/dist/dev.js:742:22 ❯ updateComputation ../node_modules/.pnpm/solid-js@1.9.10/node_modules/solid-js/dist/dev.js:724:3 ❯ createMemo ../node_modules/.pnpm/solid-js@1.9.10/node_modules/solid-js/dist/dev.js:273:10 ❯ Show ../node_modules/.pnpm/solid-js@1.9.10/node_modules/solid-js/dist/dev.js:1521:26 ❯ ../node_modules/.pnpm/solid-js@1.9.10/node_modules/solid-js/dist/dev.js:586:12 ❯ untrack ../node_modules/.pnpm/solid-js@1.9.10/node_modules/solid-js/dist/dev.js:475:12 ❯ Object.fn ../node_modules/.pnpm/solid-js@1.9.10/node_modules/solid-js/dist/dev.js:582:37 ❯ runComputation ../node_modules/.pnpm/solid-js@1.9.10/node_modules/solid-js/dist/dev.js:742:22

Check failure on line 42 in frontend/src/ts/components/ui/form/InputField.tsx

View workflow job for this annotation

GitHub Actions / ci-fe

[jsx] __tests__/components/ui/form/InputField.spec.tsx > InputField > calls handleChange on input

TypeError: Cannot read properties of undefined (reading 'validators') ❯ Object.get when [as when] src/ts/components/ui/form/InputField.tsx:42:33 ❯ Object.Show.createMemo.name [as fn] ../node_modules/.pnpm/solid-js@1.9.10/node_modules/solid-js/dist/dev.js:1521:49 ❯ runComputation ../node_modules/.pnpm/solid-js@1.9.10/node_modules/solid-js/dist/dev.js:742:22 ❯ updateComputation ../node_modules/.pnpm/solid-js@1.9.10/node_modules/solid-js/dist/dev.js:724:3 ❯ createMemo ../node_modules/.pnpm/solid-js@1.9.10/node_modules/solid-js/dist/dev.js:273:10 ❯ Show ../node_modules/.pnpm/solid-js@1.9.10/node_modules/solid-js/dist/dev.js:1521:26 ❯ ../node_modules/.pnpm/solid-js@1.9.10/node_modules/solid-js/dist/dev.js:586:12 ❯ untrack ../node_modules/.pnpm/solid-js@1.9.10/node_modules/solid-js/dist/dev.js:475:12 ❯ Object.fn ../node_modules/.pnpm/solid-js@1.9.10/node_modules/solid-js/dist/dev.js:582:37 ❯ runComputation ../node_modules/.pnpm/solid-js@1.9.10/node_modules/solid-js/dist/dev.js:742:22

Check failure on line 42 in frontend/src/ts/components/ui/form/InputField.tsx

View workflow job for this annotation

GitHub Actions / ci-fe

[jsx] __tests__/components/ui/form/InputField.spec.tsx > InputField > uses custom type

TypeError: Cannot read properties of undefined (reading 'validators') ❯ Object.get when [as when] src/ts/components/ui/form/InputField.tsx:42:33 ❯ Object.Show.createMemo.name [as fn] ../node_modules/.pnpm/solid-js@1.9.10/node_modules/solid-js/dist/dev.js:1521:49 ❯ runComputation ../node_modules/.pnpm/solid-js@1.9.10/node_modules/solid-js/dist/dev.js:742:22 ❯ updateComputation ../node_modules/.pnpm/solid-js@1.9.10/node_modules/solid-js/dist/dev.js:724:3 ❯ createMemo ../node_modules/.pnpm/solid-js@1.9.10/node_modules/solid-js/dist/dev.js:273:10 ❯ Show ../node_modules/.pnpm/solid-js@1.9.10/node_modules/solid-js/dist/dev.js:1521:26 ❯ ../node_modules/.pnpm/solid-js@1.9.10/node_modules/solid-js/dist/dev.js:586:12 ❯ untrack ../node_modules/.pnpm/solid-js@1.9.10/node_modules/solid-js/dist/dev.js:475:12 ❯ Object.fn ../node_modules/.pnpm/solid-js@1.9.10/node_modules/solid-js/dist/dev.js:582:37 ❯ runComputation ../node_modules/.pnpm/solid-js@1.9.10/node_modules/solid-js/dist/dev.js:742:22

Check failure on line 42 in frontend/src/ts/components/ui/form/InputField.tsx

View workflow job for this annotation

GitHub Actions / ci-fe

[jsx] __tests__/components/ui/form/InputField.spec.tsx > InputField > defaults to text type

TypeError: Cannot read properties of undefined (reading 'validators') ❯ Object.get when [as when] src/ts/components/ui/form/InputField.tsx:42:33 ❯ Object.Show.createMemo.name [as fn] ../node_modules/.pnpm/solid-js@1.9.10/node_modules/solid-js/dist/dev.js:1521:49 ❯ runComputation ../node_modules/.pnpm/solid-js@1.9.10/node_modules/solid-js/dist/dev.js:742:22 ❯ updateComputation ../node_modules/.pnpm/solid-js@1.9.10/node_modules/solid-js/dist/dev.js:724:3 ❯ createMemo ../node_modules/.pnpm/solid-js@1.9.10/node_modules/solid-js/dist/dev.js:273:10 ❯ Show ../node_modules/.pnpm/solid-js@1.9.10/node_modules/solid-js/dist/dev.js:1521:26 ❯ ../node_modules/.pnpm/solid-js@1.9.10/node_modules/solid-js/dist/dev.js:586:12 ❯ untrack ../node_modules/.pnpm/solid-js@1.9.10/node_modules/solid-js/dist/dev.js:475:12 ❯ Object.fn ../node_modules/.pnpm/solid-js@1.9.10/node_modules/solid-js/dist/dev.js:582:37 ❯ runComputation ../node_modules/.pnpm/solid-js@1.9.10/node_modules/solid-js/dist/dev.js:742:22

Check failure on line 42 in frontend/src/ts/components/ui/form/InputField.tsx

View workflow job for this annotation

GitHub Actions / ci-fe

[jsx] __tests__/components/ui/form/InputField.spec.tsx > InputField > uses custom placeholder when provided

TypeError: Cannot read properties of undefined (reading 'validators') ❯ Object.get when [as when] src/ts/components/ui/form/InputField.tsx:42:33 ❯ Object.Show.createMemo.name [as fn] ../node_modules/.pnpm/solid-js@1.9.10/node_modules/solid-js/dist/dev.js:1521:49 ❯ runComputation ../node_modules/.pnpm/solid-js@1.9.10/node_modules/solid-js/dist/dev.js:742:22 ❯ updateComputation ../node_modules/.pnpm/solid-js@1.9.10/node_modules/solid-js/dist/dev.js:724:3 ❯ createMemo ../node_modules/.pnpm/solid-js@1.9.10/node_modules/solid-js/dist/dev.js:273:10 ❯ Show ../node_modules/.pnpm/solid-js@1.9.10/node_modules/solid-js/dist/dev.js:1521:26 ❯ ../node_modules/.pnpm/solid-js@1.9.10/node_modules/solid-js/dist/dev.js:586:12 ❯ untrack ../node_modules/.pnpm/solid-js@1.9.10/node_modules/solid-js/dist/dev.js:475:12 ❯ Object.fn ../node_modules/.pnpm/solid-js@1.9.10/node_modules/solid-js/dist/dev.js:582:37 ❯ runComputation ../node_modules/.pnpm/solid-js@1.9.10/node_modules/solid-js/dist/dev.js:742:22

Check failure on line 42 in frontend/src/ts/components/ui/form/InputField.tsx

View workflow job for this annotation

GitHub Actions / ci-fe

[jsx] __tests__/components/ui/form/InputField.spec.tsx > InputField > hides FieldIndicator by default

TypeError: Cannot read properties of undefined (reading 'validators') ❯ Object.get when [as when] src/ts/components/ui/form/InputField.tsx:42:33 ❯ Object.Show.createMemo.name [as fn] ../node_modules/.pnpm/solid-js@1.9.10/node_modules/solid-js/dist/dev.js:1521:49 ❯ runComputation ../node_modules/.pnpm/solid-js@1.9.10/node_modules/solid-js/dist/dev.js:742:22 ❯ updateComputation ../node_modules/.pnpm/solid-js@1.9.10/node_modules/solid-js/dist/dev.js:724:3 ❯ createMemo ../node_modules/.pnpm/solid-js@1.9.10/node_modules/solid-js/dist/dev.js:273:10 ❯ Show ../node_modules/.pnpm/solid-js@1.9.10/node_modules/solid-js/dist/dev.js:1521:26 ❯ ../node_modules/.pnpm/solid-js@1.9.10/node_modules/solid-js/dist/dev.js:586:12 ❯ untrack ../node_modules/.pnpm/solid-js@1.9.10/node_modules/solid-js/dist/dev.js:475:12 ❯ Object.fn ../node_modules/.pnpm/solid-js@1.9.10/node_modules/solid-js/dist/dev.js:582:37 ❯ runComputation ../node_modules/.pnpm/solid-js@1.9.10/node_modules/solid-js/dist/dev.js:742:22

Check failure on line 42 in frontend/src/ts/components/ui/form/InputField.tsx

View workflow job for this annotation

GitHub Actions / ci-fe

[jsx] __tests__/components/ui/form/InputField.spec.tsx > InputField > shows FieldIndicator

TypeError: Cannot read properties of undefined (reading 'validators') ❯ Object.get when [as when] src/ts/components/ui/form/InputField.tsx:42:33 ❯ Object.Show.createMemo.name [as fn] ../node_modules/.pnpm/solid-js@1.9.10/node_modules/solid-js/dist/dev.js:1521:49 ❯ runComputation ../node_modules/.pnpm/solid-js@1.9.10/node_modules/solid-js/dist/dev.js:742:22 ❯ updateComputation ../node_modules/.pnpm/solid-js@1.9.10/node_modules/solid-js/dist/dev.js:724:3 ❯ createMemo ../node_modules/.pnpm/solid-js@1.9.10/node_modules/solid-js/dist/dev.js:273:10 ❯ Show ../node_modules/.pnpm/solid-js@1.9.10/node_modules/solid-js/dist/dev.js:1521:26 ❯ ../node_modules/.pnpm/solid-js@1.9.10/node_modules/solid-js/dist/dev.js:586:12 ❯ untrack ../node_modules/.pnpm/solid-js@1.9.10/node_modules/solid-js/dist/dev.js:475:12 ❯ Object.fn ../node_modules/.pnpm/solid-js@1.9.10/node_modules/solid-js/dist/dev.js:582:37 ❯ runComputation ../node_modules/.pnpm/solid-js@1.9.10/node_modules/solid-js/dist/dev.js:742:22

Check failure on line 42 in frontend/src/ts/components/ui/form/InputField.tsx

View workflow job for this annotation

GitHub Actions / ci-fe

[jsx] __tests__/components/ui/form/InputField.spec.tsx > InputField > renders disabled input

TypeError: Cannot read properties of undefined (reading 'validators') ❯ Object.get when [as when] src/ts/components/ui/form/InputField.tsx:42:33 ❯ Object.Show.createMemo.name [as fn] ../node_modules/.pnpm/solid-js@1.9.10/node_modules/solid-js/dist/dev.js:1521:49 ❯ runComputation ../node_modules/.pnpm/solid-js@1.9.10/node_modules/solid-js/dist/dev.js:742:22 ❯ updateComputation ../node_modules/.pnpm/solid-js@1.9.10/node_modules/solid-js/dist/dev.js:724:3 ❯ createMemo ../node_modules/.pnpm/solid-js@1.9.10/node_modules/solid-js/dist/dev.js:273:10 ❯ Show ../node_modules/.pnpm/solid-js@1.9.10/node_modules/solid-js/dist/dev.js:1521:26 ❯ ../node_modules/.pnpm/solid-js@1.9.10/node_modules/solid-js/dist/dev.js:586:12 ❯ untrack ../node_modules/.pnpm/solid-js@1.9.10/node_modules/solid-js/dist/dev.js:475:12 ❯ Object.fn ../node_modules/.pnpm/solid-js@1.9.10/node_modules/solid-js/dist/dev.js:582:37 ❯ runComputation ../node_modules/.pnpm/solid-js@1.9.10/node_modules/solid-js/dist/dev.js:742:22

Check failure on line 42 in frontend/src/ts/components/ui/form/InputField.tsx

View workflow job for this annotation

GitHub Actions / ci-fe

[jsx] __tests__/components/ui/form/InputField.spec.tsx > InputField > calls onFocus callback

TypeError: Cannot read properties of undefined (reading 'validators') ❯ Object.get when [as when] src/ts/components/ui/form/InputField.tsx:42:33 ❯ Object.Show.createMemo.name [as fn] ../node_modules/.pnpm/solid-js@1.9.10/node_modules/solid-js/dist/dev.js:1521:49 ❯ runComputation ../node_modules/.pnpm/solid-js@1.9.10/node_modules/solid-js/dist/dev.js:742:22 ❯ updateComputation ../node_modules/.pnpm/solid-js@1.9.10/node_modules/solid-js/dist/dev.js:724:3 ❯ createMemo ../node_modules/.pnpm/solid-js@1.9.10/node_modules/solid-js/dist/dev.js:273:10 ❯ Show ../node_modules/.pnpm/solid-js@1.9.10/node_modules/solid-js/dist/dev.js:1521:26 ❯ ../node_modules/.pnpm/solid-js@1.9.10/node_modules/solid-js/dist/dev.js:586:12 ❯ untrack ../node_modules/.pnpm/solid-js@1.9.10/node_modules/solid-js/dist/dev.js:475:12 ❯ Object.fn ../node_modules/.pnpm/solid-js@1.9.10/node_modules/solid-js/dist/dev.js:582:37 ❯ runComputation ../node_modules/.pnpm/solid-js@1.9.10/node_modules/solid-js/dist/dev.js:742:22

Check failure on line 42 in frontend/src/ts/components/ui/form/InputField.tsx

View workflow job for this annotation

GitHub Actions / ci-fe

[jsx] __tests__/components/ui/form/InputField.spec.tsx > InputField > calls handleBlur on blur

TypeError: Cannot read properties of undefined (reading 'validators') ❯ Object.get when [as when] src/ts/components/ui/form/InputField.tsx:42:33 ❯ Object.Show.createMemo.name [as fn] ../node_modules/.pnpm/solid-js@1.9.10/node_modules/solid-js/dist/dev.js:1521:49 ❯ runComputation ../node_modules/.pnpm/solid-js@1.9.10/node_modules/solid-js/dist/dev.js:742:22 ❯ updateComputation ../node_modules/.pnpm/solid-js@1.9.10/node_modules/solid-js/dist/dev.js:724:3 ❯ createMemo ../node_modules/.pnpm/solid-js@1.9.10/node_modules/solid-js/dist/dev.js:273:10 ❯ Show ../node_modules/.pnpm/solid-js@1.9.10/node_modules/solid-js/dist/dev.js:1521:26 ❯ ../node_modules/.pnpm/solid-js@1.9.10/node_modules/solid-js/dist/dev.js:586:12 ❯ untrack ../node_modules/.pnpm/solid-js@1.9.10/node_modules/solid-js/dist/dev.js:475:12 ❯ Object.fn ../node_modules/.pnpm/solid-js@1.9.10/node_modules/solid-js/dist/dev.js:582:37 ❯ runComputation ../node_modules/.pnpm/solid-js@1.9.10/node_modules/solid-js/dist/dev.js:742:22

Check failure on line 42 in frontend/src/ts/components/ui/form/InputField.tsx

View workflow job for this annotation

GitHub Actions / ci-fe

[jsx] __tests__/components/ui/form/InputField.spec.tsx > InputField > calls handleChange on input

TypeError: Cannot read properties of undefined (reading 'validators') ❯ Object.get when [as when] src/ts/components/ui/form/InputField.tsx:42:33 ❯ Object.Show.createMemo.name [as fn] ../node_modules/.pnpm/solid-js@1.9.10/node_modules/solid-js/dist/dev.js:1521:49 ❯ runComputation ../node_modules/.pnpm/solid-js@1.9.10/node_modules/solid-js/dist/dev.js:742:22 ❯ updateComputation ../node_modules/.pnpm/solid-js@1.9.10/node_modules/solid-js/dist/dev.js:724:3 ❯ createMemo ../node_modules/.pnpm/solid-js@1.9.10/node_modules/solid-js/dist/dev.js:273:10 ❯ Show ../node_modules/.pnpm/solid-js@1.9.10/node_modules/solid-js/dist/dev.js:1521:26 ❯ ../node_modules/.pnpm/solid-js@1.9.10/node_modules/solid-js/dist/dev.js:586:12 ❯ untrack ../node_modules/.pnpm/solid-js@1.9.10/node_modules/solid-js/dist/dev.js:475:12 ❯ Object.fn ../node_modules/.pnpm/solid-js@1.9.10/node_modules/solid-js/dist/dev.js:582:37 ❯ runComputation ../node_modules/.pnpm/solid-js@1.9.10/node_modules/solid-js/dist/dev.js:742:22

Check failure on line 42 in frontend/src/ts/components/ui/form/InputField.tsx

View workflow job for this annotation

GitHub Actions / ci-fe

[jsx] __tests__/components/ui/form/InputField.spec.tsx > InputField > uses custom type

TypeError: Cannot read properties of undefined (reading 'validators') ❯ Object.get when [as when] src/ts/components/ui/form/InputField.tsx:42:33 ❯ Object.Show.createMemo.name [as fn] ../node_modules/.pnpm/solid-js@1.9.10/node_modules/solid-js/dist/dev.js:1521:49 ❯ runComputation ../node_modules/.pnpm/solid-js@1.9.10/node_modules/solid-js/dist/dev.js:742:22 ❯ updateComputation ../node_modules/.pnpm/solid-js@1.9.10/node_modules/solid-js/dist/dev.js:724:3 ❯ createMemo ../node_modules/.pnpm/solid-js@1.9.10/node_modules/solid-js/dist/dev.js:273:10 ❯ Show ../node_modules/.pnpm/solid-js@1.9.10/node_modules/solid-js/dist/dev.js:1521:26 ❯ ../node_modules/.pnpm/solid-js@1.9.10/node_modules/solid-js/dist/dev.js:586:12 ❯ untrack ../node_modules/.pnpm/solid-js@1.9.10/node_modules/solid-js/dist/dev.js:475:12 ❯ Object.fn ../node_modules/.pnpm/solid-js@1.9.10/node_modules/solid-js/dist/dev.js:582:37 ❯ runComputation ../node_modules/.pnpm/solid-js@1.9.10/node_modules/solid-js/dist/dev.js:742:22

Check failure on line 42 in frontend/src/ts/components/ui/form/InputField.tsx

View workflow job for this annotation

GitHub Actions / ci-fe

[jsx] __tests__/components/ui/form/InputField.spec.tsx > InputField > defaults to text type

TypeError: Cannot read properties of undefined (reading 'validators') ❯ Object.get when [as when] src/ts/components/ui/form/InputField.tsx:42:33 ❯ Object.Show.createMemo.name [as fn] ../node_modules/.pnpm/solid-js@1.9.10/node_modules/solid-js/dist/dev.js:1521:49 ❯ runComputation ../node_modules/.pnpm/solid-js@1.9.10/node_modules/solid-js/dist/dev.js:742:22 ❯ updateComputation ../node_modules/.pnpm/solid-js@1.9.10/node_modules/solid-js/dist/dev.js:724:3 ❯ createMemo ../node_modules/.pnpm/solid-js@1.9.10/node_modules/solid-js/dist/dev.js:273:10 ❯ Show ../node_modules/.pnpm/solid-js@1.9.10/node_modules/solid-js/dist/dev.js:1521:26 ❯ ../node_modules/.pnpm/solid-js@1.9.10/node_modules/solid-js/dist/dev.js:586:12 ❯ untrack ../node_modules/.pnpm/solid-js@1.9.10/node_modules/solid-js/dist/dev.js:475:12 ❯ Object.fn ../node_modules/.pnpm/solid-js@1.9.10/node_modules/solid-js/dist/dev.js:582:37 ❯ runComputation ../node_modules/.pnpm/solid-js@1.9.10/node_modules/solid-js/dist/dev.js:742:22

Check failure on line 42 in frontend/src/ts/components/ui/form/InputField.tsx

View workflow job for this annotation

GitHub Actions / ci-fe

[jsx] __tests__/components/ui/form/InputField.spec.tsx > InputField > uses custom placeholder when provided

TypeError: Cannot read properties of undefined (reading 'validators') ❯ Object.get when [as when] src/ts/components/ui/form/InputField.tsx:42:33 ❯ Object.Show.createMemo.name [as fn] ../node_modules/.pnpm/solid-js@1.9.10/node_modules/solid-js/dist/dev.js:1521:49 ❯ runComputation ../node_modules/.pnpm/solid-js@1.9.10/node_modules/solid-js/dist/dev.js:742:22 ❯ updateComputation ../node_modules/.pnpm/solid-js@1.9.10/node_modules/solid-js/dist/dev.js:724:3 ❯ createMemo ../node_modules/.pnpm/solid-js@1.9.10/node_modules/solid-js/dist/dev.js:273:10 ❯ Show ../node_modules/.pnpm/solid-js@1.9.10/node_modules/solid-js/dist/dev.js:1521:26 ❯ ../node_modules/.pnpm/solid-js@1.9.10/node_modules/solid-js/dist/dev.js:586:12 ❯ untrack ../node_modules/.pnpm/solid-js@1.9.10/node_modules/solid-js/dist/dev.js:475:12 ❯ Object.fn ../node_modules/.pnpm/solid-js@1.9.10/node_modules/solid-js/dist/dev.js:582:37 ❯ runComputation ../node_modules/.pnpm/solid-js@1.9.10/node_modules/solid-js/dist/dev.js:742:22
<FieldIndicator field={props.field()} />
</Show>
</div>
Expand Down
10 changes: 10 additions & 0 deletions frontend/src/ts/constants/sounds.ts
Original file line number Diff line number Diff line change
Expand Up @@ -17,6 +17,16 @@ export const soundsConfig: SoundConfigType = {
14: { numberOfSounds: 8 },
15: { numberOfSounds: 5 },
16: { numberOfSounds: 8 },
17: { numberOfSounds: 10 },
18: { numberOfSounds: 10 },
19: { numberOfSounds: 10 },
20: { numberOfSounds: 10 },
21: { numberOfSounds: 10 },
22: { numberOfSounds: 10 },
23: { numberOfSounds: 10 },
24: { numberOfSounds: 10 },
25: { numberOfSounds: 10 },
26: { numberOfSounds: 10 },
};

export type ClickSoundConfig = {
Expand Down
Binary file added frontend/static/sounds/click17/1.wav
Binary file not shown.
Binary file added frontend/static/sounds/click17/10.wav
Binary file not shown.
Binary file added frontend/static/sounds/click17/2.wav
Binary file not shown.
Binary file added frontend/static/sounds/click17/3.wav
Binary file not shown.
Binary file added frontend/static/sounds/click17/4.wav
Binary file not shown.
Binary file added frontend/static/sounds/click17/5.wav
Binary file not shown.
Binary file added frontend/static/sounds/click17/6.wav
Binary file not shown.
Binary file added frontend/static/sounds/click17/7.wav
Binary file not shown.
Binary file added frontend/static/sounds/click17/8.wav
Binary file not shown.
Binary file added frontend/static/sounds/click17/9.wav
Binary file not shown.
Binary file added frontend/static/sounds/click18/1.wav
Binary file not shown.
Binary file added frontend/static/sounds/click18/10.wav
Binary file not shown.
Binary file added frontend/static/sounds/click18/2.wav
Binary file not shown.
Binary file added frontend/static/sounds/click18/3.wav
Binary file not shown.
Binary file added frontend/static/sounds/click18/4.wav
Binary file not shown.
Binary file added frontend/static/sounds/click18/5.wav
Binary file not shown.
Binary file added frontend/static/sounds/click18/6.wav
Binary file not shown.
Binary file added frontend/static/sounds/click18/7.wav
Binary file not shown.
Binary file added frontend/static/sounds/click18/8.wav
Binary file not shown.
Binary file added frontend/static/sounds/click18/9.wav
Binary file not shown.
Binary file added frontend/static/sounds/click19/1.wav
Binary file not shown.
Binary file added frontend/static/sounds/click19/10.wav
Binary file not shown.
Binary file added frontend/static/sounds/click19/2.wav
Binary file not shown.
Binary file added frontend/static/sounds/click19/3.wav
Binary file not shown.
Binary file added frontend/static/sounds/click19/4.wav
Binary file not shown.
Binary file added frontend/static/sounds/click19/5.wav
Binary file not shown.
Binary file added frontend/static/sounds/click19/6.wav
Binary file not shown.
Binary file added frontend/static/sounds/click19/7.wav
Binary file not shown.
Binary file added frontend/static/sounds/click19/8.wav
Binary file not shown.
Binary file added frontend/static/sounds/click19/9.wav
Binary file not shown.
Binary file added frontend/static/sounds/click20/1.wav
Binary file not shown.
Binary file added frontend/static/sounds/click20/10.wav
Binary file not shown.
Binary file added frontend/static/sounds/click20/2.wav
Binary file not shown.
Binary file added frontend/static/sounds/click20/3.wav
Binary file not shown.
Binary file added frontend/static/sounds/click20/4.wav
Binary file not shown.
Binary file added frontend/static/sounds/click20/5.wav
Binary file not shown.
Binary file added frontend/static/sounds/click20/6.wav
Binary file not shown.
Binary file added frontend/static/sounds/click20/7.wav
Binary file not shown.
Binary file added frontend/static/sounds/click20/8.wav
Binary file not shown.
Binary file added frontend/static/sounds/click20/9.wav
Binary file not shown.
Binary file added frontend/static/sounds/click21/1.wav
Binary file not shown.
Binary file added frontend/static/sounds/click21/10.wav
Binary file not shown.
Binary file added frontend/static/sounds/click21/2.wav
Binary file not shown.
Binary file added frontend/static/sounds/click21/3.wav
Binary file not shown.
Binary file added frontend/static/sounds/click21/4.wav
Binary file not shown.
Binary file added frontend/static/sounds/click21/5.wav
Binary file not shown.
Binary file added frontend/static/sounds/click21/6.wav
Binary file not shown.
Binary file added frontend/static/sounds/click21/7.wav
Binary file not shown.
Binary file added frontend/static/sounds/click21/8.wav
Binary file not shown.
Binary file added frontend/static/sounds/click21/9.wav
Binary file not shown.
Binary file added frontend/static/sounds/click22/1.wav
Binary file not shown.
Binary file added frontend/static/sounds/click22/10.wav
Binary file not shown.
Binary file added frontend/static/sounds/click22/2.wav
Binary file not shown.
Binary file added frontend/static/sounds/click22/3.wav
Binary file not shown.
Binary file added frontend/static/sounds/click22/4.wav
Binary file not shown.
Binary file added frontend/static/sounds/click22/5.wav
Binary file not shown.
Binary file added frontend/static/sounds/click22/6.wav
Binary file not shown.
Binary file added frontend/static/sounds/click22/7.wav
Binary file not shown.
Binary file added frontend/static/sounds/click22/8.wav
Binary file not shown.
Binary file added frontend/static/sounds/click22/9.wav
Binary file not shown.
Binary file added frontend/static/sounds/click23/1.wav
Binary file not shown.
Binary file added frontend/static/sounds/click23/10.wav
Binary file not shown.
Binary file added frontend/static/sounds/click23/2.wav
Binary file not shown.
Binary file added frontend/static/sounds/click23/3.wav
Binary file not shown.
Binary file added frontend/static/sounds/click23/4.wav
Binary file not shown.
Binary file added frontend/static/sounds/click23/5.wav
Binary file not shown.
Binary file added frontend/static/sounds/click23/6.wav
Binary file not shown.
Binary file added frontend/static/sounds/click23/7.wav
Binary file not shown.
Binary file added frontend/static/sounds/click23/8.wav
Binary file not shown.
Binary file added frontend/static/sounds/click23/9.wav
Binary file not shown.
Binary file added frontend/static/sounds/click24/1.wav
Binary file not shown.
Binary file added frontend/static/sounds/click24/10.wav
Binary file not shown.
Binary file added frontend/static/sounds/click24/2.wav
Binary file not shown.
Binary file added frontend/static/sounds/click24/3.wav
Binary file not shown.
Binary file added frontend/static/sounds/click24/4.wav
Binary file not shown.
Binary file added frontend/static/sounds/click24/5.wav
Binary file not shown.
Binary file added frontend/static/sounds/click24/6.wav
Binary file not shown.
Binary file added frontend/static/sounds/click24/7.wav
Binary file not shown.
Binary file added frontend/static/sounds/click24/8.wav
Binary file not shown.
Binary file added frontend/static/sounds/click24/9.wav
Binary file not shown.
Binary file added frontend/static/sounds/click25/1.wav
Binary file not shown.
Binary file added frontend/static/sounds/click25/10.wav
Binary file not shown.
Binary file added frontend/static/sounds/click25/2.wav
Binary file not shown.
Binary file added frontend/static/sounds/click25/3.wav
Binary file not shown.
Binary file added frontend/static/sounds/click25/4.wav
Binary file not shown.
Binary file added frontend/static/sounds/click25/5.wav
Binary file not shown.
Binary file added frontend/static/sounds/click25/6.wav
Binary file not shown.
Binary file added frontend/static/sounds/click25/7.wav
Binary file not shown.
Binary file added frontend/static/sounds/click25/8.wav
Binary file not shown.
Binary file added frontend/static/sounds/click25/9.wav
Binary file not shown.
Binary file added frontend/static/sounds/click26/1.wav
Binary file not shown.
Binary file added frontend/static/sounds/click26/10.wav
Binary file not shown.
Binary file added frontend/static/sounds/click26/2.wav
Binary file not shown.
Binary file added frontend/static/sounds/click26/3.wav
Binary file not shown.
Binary file added frontend/static/sounds/click26/4.wav
Binary file not shown.
Binary file added frontend/static/sounds/click26/5.wav
Binary file not shown.
Binary file added frontend/static/sounds/click26/6.wav
Binary file not shown.
Binary file added frontend/static/sounds/click26/7.wav
Binary file not shown.
Binary file added frontend/static/sounds/click26/8.wav
Binary file not shown.
Binary file added frontend/static/sounds/click26/9.wav
Binary file not shown.
2 changes: 0 additions & 2 deletions frontend/storybook/stories/Form.stories.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -64,7 +64,6 @@ export const withValidation = meta.story({
children={(field) => (
<InputField
field={field}
showIndicator
autocomplete="current-user"
disabled={!isEditable()}
/>
Expand All @@ -79,7 +78,6 @@ export const withValidation = meta.story({
<InputField
field={field}
type="password"
showIndicator
autocomplete="current-password"
disabled={!isEditable()}
/>
Expand Down
10 changes: 10 additions & 0 deletions packages/schemas/src/configs.ts
Original file line number Diff line number Diff line change
Expand Up @@ -144,6 +144,16 @@ export const PlaySoundOnClickSchema = z.enum([
"14",
"15",
"16",
"17",
"18",
"19",
"20",
"21",
"22",
"23",
"24",
"25",
"26",
]);
export type PlaySoundOnClick = z.infer<typeof PlaySoundOnClickSchema>;

Expand Down
Loading