Skip to content

Commit facc649

Browse files
freds-devmpfeildependabot[bot]
authored
update beta (#524)
* migrate to rr7 (#482) * migrate to rr7 * adjust `/explore` route to new routing * adjust all routes to new routing except `/resources` * fix `duplicate imports` eslint errors * update `package-lock.json` * fix TS errors * fix more TypeScript errors * fix Photo upload on react-router * delete set-theme route * fix `.mdx` typegen errors * fix session * remove navigate and use Link * ensure same sensor order * fix wrong loader import * migrate to rr7 (#487) * fix eslint warnings * remove markdown * fix ESLint --------- Co-authored-by: freds-dev <[email protected]> --------- Co-authored-by: freds-dev <[email protected]> * build(deps): bump tailwind-merge from 1.14.0 to 2.6.0 (#483) Bumps [tailwind-merge](https://github.com/dcastil/tailwind-merge) from 1.14.0 to 2.6.0. - [Release notes](https://github.com/dcastil/tailwind-merge/releases) - [Commits](dcastil/tailwind-merge@v1.14.0...v2.6.0) --- updated-dependencies: - dependency-name: tailwind-merge dependency-type: direct:production update-type: version-update:semver-major ... Signed-off-by: dependabot[bot] <[email protected]> Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com> * build(deps): bump chroma-js and @types/chroma-js (#484) Bumps [chroma-js](https://github.com/gka/chroma.js) and [@types/chroma-js](https://github.com/DefinitelyTyped/DefinitelyTyped/tree/HEAD/types/chroma-js). These dependencies needed to be updated together. Updates `chroma-js` from 2.6.0 to 3.1.2 - [Release notes](https://github.com/gka/chroma.js/releases) - [Changelog](https://github.com/gka/chroma.js/blob/main/CHANGELOG.md) - [Commits](gka/chroma.js@v2.6.0...v3.1.2) Updates `@types/chroma-js` from 2.4.5 to 3.1.0 - [Release notes](https://github.com/DefinitelyTyped/DefinitelyTyped/releases) - [Commits](https://github.com/DefinitelyTyped/DefinitelyTyped/commits/HEAD/types/chroma-js) --- updated-dependencies: - dependency-name: chroma-js dependency-type: direct:production update-type: version-update:semver-major - dependency-name: "@types/chroma-js" dependency-type: direct:development update-type: version-update:semver-major ... Signed-off-by: dependabot[bot] <[email protected]> Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com> * build(deps): bump drizzle-orm from 0.36.4 to 0.38.3 (#480) Bumps [drizzle-orm](https://github.com/drizzle-team/drizzle-orm) from 0.36.4 to 0.38.3. - [Release notes](https://github.com/drizzle-team/drizzle-orm/releases) - [Commits](drizzle-team/drizzle-orm@0.36.4...0.38.3) --- updated-dependencies: - dependency-name: drizzle-orm dependency-type: direct:production update-type: version-update:semver-minor ... Signed-off-by: dependabot[bot] <[email protected]> Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com> Co-authored-by: Fred <[email protected]> * build(deps-dev): bump cookie from 0.6.0 to 1.0.2 (#489) Bumps [cookie](https://github.com/jshttp/cookie) from 0.6.0 to 1.0.2. - [Release notes](https://github.com/jshttp/cookie/releases) - [Commits](jshttp/cookie@v0.6.0...v1.0.2) --- updated-dependencies: - dependency-name: cookie dependency-type: direct:development update-type: version-update:semver-major ... Signed-off-by: dependabot[bot] <[email protected]> Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com> * build(deps-dev): bump msw from 1.3.5 to 2.7.0 (#490) * build(deps-dev): bump msw from 1.3.5 to 2.7.0 Bumps [msw](https://github.com/mswjs/msw) from 1.3.5 to 2.7.0. - [Release notes](https://github.com/mswjs/msw/releases) - [Changelog](https://github.com/mswjs/msw/blob/main/CHANGELOG.md) - [Commits](mswjs/msw@v1.3.5...v2.7.0) --- updated-dependencies: - dependency-name: msw dependency-type: direct:development update-type: version-update:semver-major ... Signed-off-by: dependabot[bot] <[email protected]> * update `package-lock.json` --------- Signed-off-by: dependabot[bot] <[email protected]> Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com> Co-authored-by: freds-dev <[email protected]> * build(deps): bump react-router from 7.1.1 to 7.1.3 (#491) Bumps [react-router](https://github.com/remix-run/react-router/tree/HEAD/packages/react-router) from 7.1.1 to 7.1.3. - [Release notes](https://github.com/remix-run/react-router/releases) - [Changelog](https://github.com/remix-run/react-router/blob/main/packages/react-router/CHANGELOG.md) - [Commits](https://github.com/remix-run/react-router/commits/[email protected]/packages/react-router) --- updated-dependencies: - dependency-name: react-router dependency-type: direct:production update-type: version-update:semver-patch ... Signed-off-by: dependabot[bot] <[email protected]> Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com> Co-authored-by: Fred <[email protected]> * remove unused dependency and fix `expiresAt` device field (#493) * build(deps): update react-map-gl to 7.1.8 and shadcn-ui to 0.9.4 (#495) * remove old express prometheus middleware (#501) * build(deps): bump @novu/notification-center from 0.15.0 to 2.0.0 (#498) Bumps [@novu/notification-center](https://github.com/novuhq/novu) from 0.15.0 to 2.0.0. - [Release notes](https://github.com/novuhq/novu/releases) - [Commits](novuhq/novu@v0.15.0...v2.0.0) --- updated-dependencies: - dependency-name: "@novu/notification-center" dependency-type: direct:production update-type: version-update:semver-major ... Signed-off-by: dependabot[bot] <[email protected]> Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com> Co-authored-by: Fred <[email protected]> * build(deps-dev): bump @vitest/coverage-v8 from 2.1.8 to 3.0.4 (#500) * build(deps-dev): bump @vitest/coverage-v8 from 2.1.8 to 3.0.4 Bumps [@vitest/coverage-v8](https://github.com/vitest-dev/vitest/tree/HEAD/packages/coverage-v8) from 2.1.8 to 3.0.4. - [Release notes](https://github.com/vitest-dev/vitest/releases) - [Commits](https://github.com/vitest-dev/vitest/commits/v3.0.4/packages/coverage-v8) --- updated-dependencies: - dependency-name: "@vitest/coverage-v8" dependency-type: direct:development update-type: version-update:semver-major ... Signed-off-by: dependabot[bot] <[email protected]> * build(deps): update vitest to version 3.0.4 and add coverage to .gitignore --------- Signed-off-by: dependabot[bot] <[email protected]> Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com> Co-authored-by: Fred <[email protected]> Co-authored-by: freds-dev <[email protected]> * build(deps-dev): bump typescript from 5.1.6 to 5.7.3 (#499) Bumps [typescript](https://github.com/microsoft/TypeScript) from 5.1.6 to 5.7.3. - [Release notes](https://github.com/microsoft/TypeScript/releases) - [Changelog](https://github.com/microsoft/TypeScript/blob/main/azure-pipelines.release.yml) - [Commits](microsoft/TypeScript@v5.1.6...v5.7.3) --- updated-dependencies: - dependency-name: typescript dependency-type: direct:development update-type: version-update:semver-minor ... Signed-off-by: dependabot[bot] <[email protected]> Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com> Co-authored-by: Fred <[email protected]> * Fix: move to bigserial (#502) * change to bigserial * use bigserial and bigint with foreign key constraints * fix(schema): change locationId type to BigInt in SensorWithMeasurementData --------- Co-authored-by: Matthias Pfeil <[email protected]> * update `connect_timeout` for migration * build(deps-dev): bump eslint-config-prettier from 8.10.0 to 10.0.1 (#506) Bumps [eslint-config-prettier](https://github.com/prettier/eslint-config-prettier) from 8.10.0 to 10.0.1. - [Release notes](https://github.com/prettier/eslint-config-prettier/releases) - [Changelog](https://github.com/prettier/eslint-config-prettier/blob/main/CHANGELOG.md) - [Commits](prettier/eslint-config-prettier@v8.10.0...v10.0.1) --- updated-dependencies: - dependency-name: eslint-config-prettier dependency-type: direct:development update-type: version-update:semver-major ... Signed-off-by: dependabot[bot] <[email protected]> Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com> * Create LICENSE * build(deps-dev): bump postcss from 8.5.1 to 8.5.2 (#508) Bumps [postcss](https://github.com/postcss/postcss) from 8.5.1 to 8.5.2. - [Release notes](https://github.com/postcss/postcss/releases) - [Changelog](https://github.com/postcss/postcss/blob/main/CHANGELOG.md) - [Commits](postcss/postcss@8.5.1...8.5.2) --- updated-dependencies: - dependency-name: postcss dependency-type: direct:development update-type: version-update:semver-patch ... Signed-off-by: dependabot[bot] <[email protected]> Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com> * refactor: change line chart to scatter chart and update related data handling (#520) --------- Signed-off-by: dependabot[bot] <[email protected]> Co-authored-by: Matthias Pfeil <[email protected]> Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
1 parent 7815eb7 commit facc649

File tree

198 files changed

+8398
-13642
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

198 files changed

+8398
-13642
lines changed

.eslintrc.cjs

Lines changed: 0 additions & 44 deletions
This file was deleted.

.gitignore

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -19,3 +19,7 @@ measurements.csv
1919
/playwright-report/
2020
/blob-report/
2121
/playwright/.cache/
22+
23+
.react-router/
24+
25+
/coverage

LICENSE

Lines changed: 21 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,21 @@
1+
MIT License
2+
3+
Copyright (c) 2025 openSenseMap
4+
5+
Permission is hereby granted, free of charge, to any person obtaining a copy
6+
of this software and associated documentation files (the "Software"), to deal
7+
in the Software without restriction, including without limitation the rights
8+
to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
9+
copies of the Software, and to permit persons to whom the Software is
10+
furnished to do so, subject to the following conditions:
11+
12+
The above copyright notice and this permission notice shall be included in all
13+
copies or substantial portions of the Software.
14+
15+
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
16+
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
17+
FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
18+
AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
19+
LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
20+
OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
21+
SOFTWARE.

app/components/aggregation-filter.tsx

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -1,10 +1,10 @@
1+
import * as SelectPrimitive from "@radix-ui/react-select";
12
import { Filter } from "lucide-react";
2-
import { Separator } from "./ui/separator";
3+
import { useSearchParams, useSubmit } from "react-router";
34
import { Badge } from "./ui/badge";
4-
import { useSearchParams, useSubmit } from "@remix-run/react";
5-
import * as SelectPrimitive from "@radix-ui/react-select";
65

76
import { Select, SelectContent, SelectItem } from "./ui/select";
7+
import { Separator } from "./ui/separator";
88

99
type Aggregation = {
1010
value: string;
@@ -52,7 +52,7 @@ export function AggregationFilter() {
5252
value={selectedAggregation?.value}
5353
onValueChange={(value) => {
5454
searchParams.set("aggregation", value);
55-
submit(searchParams);
55+
void submit(searchParams);
5656
}}
5757
>
5858
<SelectPrimitive.Trigger

app/components/color-picker.tsx

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,14 +1,13 @@
11
"use client";
22

3+
import { X } from "lucide-react";
34
import { Button } from "@/components/ui/button";
45
import { Input } from "@/components/ui/input";
5-
import { X } from "lucide-react";
66

77
export function ColorPicker({
88
handleColorChange,
99
colorPickerState,
1010
setColorPickerState,
11-
className,
1211
}: {
1312
handleColorChange: (color: string, index: number) => void;
1413
colorPickerState: {

app/components/daterange-filter.tsx

Lines changed: 17 additions & 16 deletions
Original file line numberDiff line numberDiff line change
@@ -1,8 +1,12 @@
1+
import { PopoverClose } from "@radix-ui/react-popover";
2+
import { format } from "date-fns";
13
import { Clock } from "lucide-react";
2-
import { Button } from "./ui/button";
3-
import { Popover, PopoverContent, PopoverTrigger } from "./ui/popover";
4-
import { Separator } from "./ui/separator";
4+
import { useEffect, useState } from "react";
5+
import { type DateRange } from "react-day-picker";
6+
import { useLoaderData, useSearchParams, useSubmit } from "react-router";
57
import { Badge } from "./ui/badge";
8+
import { Button } from "./ui/button";
9+
import { Calendar } from "./ui/calendar";
610
import {
711
Command,
812
CommandEmpty,
@@ -11,14 +15,10 @@ import {
1115
CommandItem,
1216
CommandList,
1317
} from "./ui/command";
14-
import { useEffect, useState } from "react";
15-
import { Calendar } from "./ui/calendar";
16-
import { useLoaderData, useSearchParams, useSubmit } from "@remix-run/react";
17-
import type { loader } from "~/routes/explore+/$deviceId+/_$deviceId";
18-
import type { DateRange } from "react-day-picker";
19-
import { PopoverClose } from "@radix-ui/react-popover";
18+
import { Popover, PopoverContent, PopoverTrigger } from "./ui/popover";
19+
import { Separator } from "./ui/separator";
2020
import dateTimeRanges from "~/lib/date-ranges";
21-
import { format } from "date-fns";
21+
import { type loader } from "~/routes/explore.$deviceId.$sensorId.$";
2222

2323
export function DateRangeFilter() {
2424
// Get data from the loader
@@ -39,14 +39,15 @@ export function DateRangeFilter() {
3939
if (
4040
!date?.from &&
4141
!date?.to &&
42+
loaderData.sensors &&
43+
loaderData.sensors.length > 0 &&
44+
loaderData.sensors[0].data &&
4245
loaderData.sensors[0].data.length > 0
4346
) {
44-
// on initial load, without a selected time range, check what time rage the last 20000 data points are in
45-
const firstDate = loaderData.sensors[0].data[0].time;
47+
const firstDate = loaderData.sensors[0].data[0]?.time;
4648
const lastDate =
47-
loaderData.sensors[0].data[
48-
loaderData.sensors[0].data.length - 1
49-
].time;
49+
loaderData.sensors[0].data[loaderData.sensors[0].data.length - 1]?.time;
50+
5051
setDate({
5152
from: lastDate ? new Date(lastDate) : undefined,
5253
to: firstDate ? new Date(firstDate) : undefined,
@@ -157,7 +158,7 @@ export function DateRangeFilter() {
157158
<PopoverClose
158159
className="inline-flex h-10 items-center justify-center rounded-md bg-primary px-4 py-2 text-sm font-medium text-primary-foreground ring-offset-background transition-colors hover:bg-primary/90 focus-visible:outline-none focus-visible:ring-2 focus-visible:ring-ring focus-visible:ring-offset-2 disabled:pointer-events-none disabled:opacity-50"
159160
onClick={() => {
160-
submit(searchParams);
161+
void submit(searchParams);
161162
}}
162163
>
163164
Apply

app/components/device-card.tsx

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -6,7 +6,7 @@ import {
66
CardHeader,
77
CardTitle,
88
} from "./ui/card";
9-
import type { Device } from "~/schema";
9+
import { type Device } from "~/schema";
1010

1111
interface DeviceCardProps {
1212
device: Device;

0 commit comments

Comments
 (0)