Skip to content

Commit 63985cf

Browse files
authored
fix: Update @seamapi/http with longer action attempt timeout (#720)
* fix: Update @seamapi/http with longer action attempt timeout * Update types * fix: Type error in stories * fix: Update cache with can_use_with_thermostat_daily_programs * feat: Support Eco mode
2 parents 3239cf3 + 6b501de commit 63985cf

File tree

8 files changed

+32
-22
lines changed

8 files changed

+32
-22
lines changed

package-lock.json

Lines changed: 17 additions & 17 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

package.json

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -128,7 +128,7 @@
128128
},
129129
"dependencies": {
130130
"@floating-ui/react": "^0.27.5",
131-
"@seamapi/http": "^1.45.0",
131+
"@seamapi/http": "^1.95.1",
132132
"@seamapi/react-query": "^0.2.0",
133133
"@tanstack/react-query": "^5.27.5",
134134
"classnames": "^2.3.2",
@@ -146,7 +146,7 @@
146146
"@rxfork/r2wc-react-to-web-component": "^2.4.0",
147147
"@seamapi/fake-devicedb": "^1.6.1",
148148
"@seamapi/fake-seam-connect": "^1.76.0",
149-
"@seamapi/types": "^1.441.1",
149+
"@seamapi/types": "^1.678.0",
150150
"@storybook/addon-designs": "^7.0.1",
151151
"@storybook/addon-essentials": "^7.0.2",
152152
"@storybook/addon-links": "^7.0.2",

src/lib/seam/components/AccessCodeTable/AccessCodeHealthBar.stories.tsx

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -41,6 +41,7 @@ export const Content: Story = {
4141
type: 'ongoing',
4242
code: '1234',
4343
status: 'setting',
44+
workspace_id: 'workspace_1',
4445
is_managed: true,
4546
is_one_time_use: false,
4647
is_offline_access_code: false,
@@ -73,6 +74,7 @@ export const Content: Story = {
7374
type: 'ongoing',
7475
code: '1234',
7576
status: 'setting',
77+
workspace_id: 'workspace_1',
7678
is_backup_access_code_available: false,
7779
is_managed: true,
7880
is_one_time_use: false,

src/lib/seam/components/DeviceTable/DeviceHealthBar.stories.tsx

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -52,6 +52,7 @@ export const Content: Story = {
5252
capabilities_supported: [],
5353
created_at: '2023-05-08T22:38:30.963Z',
5454
workspace_id: 'workspace_1',
55+
space_ids: [],
5556
properties: {
5657
name: 'mydevice',
5758
online: true,
@@ -89,6 +90,7 @@ export const Content: Story = {
8990
capabilities_supported: [],
9091
created_at: '2023-05-08T22:38:30.963Z',
9192
workspace_id: 'workspace_1',
93+
space_ids: [],
9294
custom_metadata: {},
9395
display_name: 'mydevice',
9496
location: {},

src/lib/seam/thermostats/use-create-thermostat-climate-preset.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -85,7 +85,7 @@ const getUpdatedDevice = (
8585
display_name: variables.name ?? variables.climate_preset_key,
8686
can_delete: true,
8787
can_edit: true,
88-
can_program: true,
88+
can_use_with_thermostat_daily_programs: false,
8989
manual_override_allowed: false,
9090
}
9191

src/lib/seam/thermostats/use-update-thermostat-climate-preset.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -85,7 +85,7 @@ function getUpdatedDevice(
8585
display_name: variables.name ?? variables.climate_preset_key,
8686
can_delete: true,
8787
can_edit: true,
88-
can_program: true,
88+
can_use_with_thermostat_daily_programs: false,
8989
manual_override_allowed: true,
9090
}
9191

src/lib/ui/AccessCodeForm/AccessCodeForm.stories.tsx

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -19,6 +19,7 @@ const meta: Meta<typeof AccessCodeForm> = {
1919
display_name: 'Device 1',
2020
custom_metadata: {},
2121
location: {},
22+
space_ids: [],
2223
properties: {
2324
name: '',
2425
manufacturer: undefined,

src/lib/ui/thermostat/ClimateModeMenu.tsx

Lines changed: 6 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -92,12 +92,17 @@ function ModeIcon(props: { mode: HvacModeSetting }): JSX.Element {
9292
return <ThermostatHeatCoolIcon />
9393
case 'off':
9494
return <OffIcon />
95+
case 'eco':
96+
return <ThermostatHeatCoolIcon />
97+
default:
98+
return <OffIcon />
9599
}
96100
}
97101

98-
const t = {
102+
const t: Record<HvacModeSetting, string> = {
99103
heat: 'Heat',
100104
cool: 'Cool',
101105
heat_cool: 'Heat & Cool',
102106
off: 'Off',
107+
eco: 'Eco',
103108
}

0 commit comments

Comments
 (0)