@glasshome/widget-sdk 1.30.0 → 1.31.1
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/data.d.ts +10 -1
- package/dist/deprecations.js +13 -0
- package/dist/export-history.json +298 -0
- package/dist/index.d.ts +2 -0
- package/dist/index.js +870 -865
- package/dist/media/camera-source.d.ts +21 -0
- package/dist/media/camera-source.js +39 -0
- package/dist/media/camera-stream.d.ts +18 -0
- package/dist/media/camera-stream.js +176 -0
- package/dist/media/drivers/hls.d.ts +2 -0
- package/dist/media/drivers/types.d.ts +11 -0
- package/dist/media/drivers/webrtc.d.ts +3 -0
- package/package.json +9 -3
package/dist/data.d.ts
CHANGED
|
@@ -5,7 +5,16 @@
|
|
|
5
5
|
* import map), and a direct import would bundle a second, disconnected
|
|
6
6
|
* store. Phase 4 routes these through capability checks.
|
|
7
7
|
*/
|
|
8
|
-
|
|
8
|
+
import * as syncLayer from "@glasshome/sync-layer";
|
|
9
|
+
export { getForecasts, hassMediaUrl, state, trackEntityHistory, untrackEntityHistory, } from "@glasshome/sync-layer";
|
|
10
|
+
/** @deprecated since 1.31.0, removed in 2.0.0. Use `<CameraStream entityId kind="hls">`. */
|
|
11
|
+
export declare const getStream: typeof syncLayer.getStream;
|
|
12
|
+
/** @deprecated since 1.31.0, removed in 2.0.0. Use `<CameraStream entityId kind="webrtc">`. */
|
|
13
|
+
export declare const getWebRtcClientConfig: typeof syncLayer.getWebRtcClientConfig;
|
|
14
|
+
/** @deprecated since 1.31.0, removed in 2.0.0. Use `<CameraStream entityId kind="webrtc">`. */
|
|
15
|
+
export declare const startWebRtcSession: typeof syncLayer.startWebRtcSession;
|
|
16
|
+
/** @deprecated since 1.31.0, removed in 2.0.0. Use `<CameraStream entityId kind="webrtc">`. */
|
|
17
|
+
export declare const sendWebRtcCandidate: typeof syncLayer.sendWebRtcCandidate;
|
|
9
18
|
export type { AreaView, CalendarEvent, CalendarEventsData, CalendarWindowOptions, ForecastType, WeatherForecast, } from "@glasshome/sync-layer";
|
|
10
19
|
export { byDomain, useArea, useCalendarEvents, useCamera, useConnection, useCurrency, useEntities, useEntity, useEntityHistory, useEntityStatistics, useForecast, useHassConfig, useLocale, useStore, useTemperatureUnit, useUnitSystem, } from "@glasshome/sync-layer/solid";
|
|
11
20
|
export { useService, useToggle, useTurnOff, useTurnOn } from "./framework/hooks/use-service";
|
package/dist/deprecations.js
CHANGED
|
@@ -111,6 +111,19 @@ var e = "https://glasshome.app/docs/widget-sdk/config", t = [
|
|
|
111
111
|
docsUrl: "https://glasshome.app/docs/widgets/widget-sealed-engine",
|
|
112
112
|
sourcePattern: "\\binstantiateWidget\\b"
|
|
113
113
|
},
|
|
114
|
+
...[
|
|
115
|
+
"getStream",
|
|
116
|
+
"getWebRtcClientConfig",
|
|
117
|
+
"startWebRtcSession",
|
|
118
|
+
"sendWebRtcCandidate"
|
|
119
|
+
].map((e) => ({
|
|
120
|
+
id: e,
|
|
121
|
+
since: "1.31.0",
|
|
122
|
+
removeIn: "2.0.0",
|
|
123
|
+
replacement: "<CameraStream entityId kind>",
|
|
124
|
+
docsUrl: "https://glasshome.app/docs/widgets/widget-api-reference",
|
|
125
|
+
sourcePattern: `\\b${e}\\b`
|
|
126
|
+
})),
|
|
114
127
|
{
|
|
115
128
|
id: "WidgetContext.theme",
|
|
116
129
|
since: "1.26.0",
|
package/dist/export-history.json
CHANGED
|
@@ -6145,5 +6145,303 @@
|
|
|
6145
6145
|
"useWidgetViewer",
|
|
6146
6146
|
"widgetFields",
|
|
6147
6147
|
"z"
|
|
6148
|
+
],
|
|
6149
|
+
"1.31.0": [
|
|
6150
|
+
"Badge",
|
|
6151
|
+
"Button",
|
|
6152
|
+
"ButtonGroup",
|
|
6153
|
+
"CameraSourceContext",
|
|
6154
|
+
"CameraStream",
|
|
6155
|
+
"Carousel",
|
|
6156
|
+
"CarouselContent",
|
|
6157
|
+
"CarouselDots",
|
|
6158
|
+
"CarouselItem",
|
|
6159
|
+
"CarouselNext",
|
|
6160
|
+
"CarouselPrevious",
|
|
6161
|
+
"ColorDisc",
|
|
6162
|
+
"ColorSlider",
|
|
6163
|
+
"ColorWheel",
|
|
6164
|
+
"CountPill",
|
|
6165
|
+
"Icon",
|
|
6166
|
+
"Input",
|
|
6167
|
+
"Label",
|
|
6168
|
+
"PanelEntityRow",
|
|
6169
|
+
"PanelFacts",
|
|
6170
|
+
"PanelRow",
|
|
6171
|
+
"PanelRows",
|
|
6172
|
+
"PanelSection",
|
|
6173
|
+
"Progress",
|
|
6174
|
+
"ResponsiveDialog",
|
|
6175
|
+
"ResponsiveDialogBody",
|
|
6176
|
+
"ResponsiveDialogClose",
|
|
6177
|
+
"ResponsiveDialogContent",
|
|
6178
|
+
"ResponsiveDialogDescription",
|
|
6179
|
+
"ResponsiveDialogFooter",
|
|
6180
|
+
"ResponsiveDialogHeader",
|
|
6181
|
+
"ResponsiveDialogTitle",
|
|
6182
|
+
"SDK_VERSION",
|
|
6183
|
+
"SchemaForm",
|
|
6184
|
+
"SectionIcon",
|
|
6185
|
+
"SectionTitle",
|
|
6186
|
+
"Select",
|
|
6187
|
+
"SelectContent",
|
|
6188
|
+
"SelectItem",
|
|
6189
|
+
"SelectTrigger",
|
|
6190
|
+
"SelectValue",
|
|
6191
|
+
"Slider",
|
|
6192
|
+
"SwatchPicker",
|
|
6193
|
+
"Switch",
|
|
6194
|
+
"Tabs",
|
|
6195
|
+
"TabsContent",
|
|
6196
|
+
"TabsList",
|
|
6197
|
+
"TabsTrigger",
|
|
6198
|
+
"TemperatureBar",
|
|
6199
|
+
"Toggle",
|
|
6200
|
+
"ToggleGroup",
|
|
6201
|
+
"ToggleGroupItem",
|
|
6202
|
+
"ToneSchema",
|
|
6203
|
+
"Widget",
|
|
6204
|
+
"WidgetAction",
|
|
6205
|
+
"WidgetBackdrop",
|
|
6206
|
+
"WidgetChip",
|
|
6207
|
+
"WidgetChoice",
|
|
6208
|
+
"WidgetContent",
|
|
6209
|
+
"WidgetControls",
|
|
6210
|
+
"WidgetCtx",
|
|
6211
|
+
"WidgetDebugTab",
|
|
6212
|
+
"WidgetDebugView",
|
|
6213
|
+
"WidgetDialog",
|
|
6214
|
+
"WidgetGlyph",
|
|
6215
|
+
"WidgetHead",
|
|
6216
|
+
"WidgetHero",
|
|
6217
|
+
"WidgetIcon",
|
|
6218
|
+
"WidgetLayer",
|
|
6219
|
+
"WidgetManifestSchema",
|
|
6220
|
+
"WidgetSizeCtx",
|
|
6221
|
+
"WidgetSliderFill",
|
|
6222
|
+
"WidgetStatus",
|
|
6223
|
+
"WidgetStepper",
|
|
6224
|
+
"WidgetTitle",
|
|
6225
|
+
"WidgetValue",
|
|
6226
|
+
"buildDebugData",
|
|
6227
|
+
"byDomain",
|
|
6228
|
+
"calculateLightGroup",
|
|
6229
|
+
"calculateSensorGroup",
|
|
6230
|
+
"copyText",
|
|
6231
|
+
"countActiveEntities",
|
|
6232
|
+
"defineConfig",
|
|
6233
|
+
"defineWidget",
|
|
6234
|
+
"deprecations",
|
|
6235
|
+
"field",
|
|
6236
|
+
"formatDeprecation",
|
|
6237
|
+
"formatSchemaError",
|
|
6238
|
+
"getEntityAttribute",
|
|
6239
|
+
"getForecasts",
|
|
6240
|
+
"getStream",
|
|
6241
|
+
"getWebRtcClientConfig",
|
|
6242
|
+
"hassMediaUrl",
|
|
6243
|
+
"imagePreset",
|
|
6244
|
+
"imageSrc",
|
|
6245
|
+
"imageUrl",
|
|
6246
|
+
"injectTokens",
|
|
6247
|
+
"isDark",
|
|
6248
|
+
"isEntityActive",
|
|
6249
|
+
"isPanelControllable",
|
|
6250
|
+
"mediaUrl",
|
|
6251
|
+
"monotoneCubicPath",
|
|
6252
|
+
"parseColor",
|
|
6253
|
+
"presetValue",
|
|
6254
|
+
"provideCameraSource",
|
|
6255
|
+
"sendWebRtcCandidate",
|
|
6256
|
+
"startWebRtcSession",
|
|
6257
|
+
"state",
|
|
6258
|
+
"svgColors",
|
|
6259
|
+
"trackEntityHistory",
|
|
6260
|
+
"untrackEntityHistory",
|
|
6261
|
+
"useArea",
|
|
6262
|
+
"useCalendarEvents",
|
|
6263
|
+
"useCamera",
|
|
6264
|
+
"useCameraSource",
|
|
6265
|
+
"useConfirm",
|
|
6266
|
+
"useConnection",
|
|
6267
|
+
"useCopyText",
|
|
6268
|
+
"useCurrency",
|
|
6269
|
+
"useDaylight",
|
|
6270
|
+
"useEntities",
|
|
6271
|
+
"useEntity",
|
|
6272
|
+
"useEntityHistory",
|
|
6273
|
+
"useEntityStatistics",
|
|
6274
|
+
"useForecast",
|
|
6275
|
+
"useHassConfig",
|
|
6276
|
+
"useIntersectionPause",
|
|
6277
|
+
"useLocale",
|
|
6278
|
+
"useMaterial",
|
|
6279
|
+
"useReducedMotion",
|
|
6280
|
+
"useService",
|
|
6281
|
+
"useStore",
|
|
6282
|
+
"useTemperatureUnit",
|
|
6283
|
+
"useToggle",
|
|
6284
|
+
"useTurnOff",
|
|
6285
|
+
"useTurnOn",
|
|
6286
|
+
"useUnitSystem",
|
|
6287
|
+
"useWidgetContext",
|
|
6288
|
+
"useWidgetDashboard",
|
|
6289
|
+
"useWidgetDialog",
|
|
6290
|
+
"useWidgetDimensions",
|
|
6291
|
+
"useWidgetEntityGroup",
|
|
6292
|
+
"useWidgetGestures",
|
|
6293
|
+
"useWidgetState",
|
|
6294
|
+
"useWidgetViewer",
|
|
6295
|
+
"widgetFields",
|
|
6296
|
+
"z"
|
|
6297
|
+
],
|
|
6298
|
+
"1.31.1": [
|
|
6299
|
+
"Badge",
|
|
6300
|
+
"Button",
|
|
6301
|
+
"ButtonGroup",
|
|
6302
|
+
"CameraSourceContext",
|
|
6303
|
+
"CameraStream",
|
|
6304
|
+
"Carousel",
|
|
6305
|
+
"CarouselContent",
|
|
6306
|
+
"CarouselDots",
|
|
6307
|
+
"CarouselItem",
|
|
6308
|
+
"CarouselNext",
|
|
6309
|
+
"CarouselPrevious",
|
|
6310
|
+
"ColorDisc",
|
|
6311
|
+
"ColorSlider",
|
|
6312
|
+
"ColorWheel",
|
|
6313
|
+
"CountPill",
|
|
6314
|
+
"Icon",
|
|
6315
|
+
"Input",
|
|
6316
|
+
"Label",
|
|
6317
|
+
"PanelEntityRow",
|
|
6318
|
+
"PanelFacts",
|
|
6319
|
+
"PanelRow",
|
|
6320
|
+
"PanelRows",
|
|
6321
|
+
"PanelSection",
|
|
6322
|
+
"Progress",
|
|
6323
|
+
"ResponsiveDialog",
|
|
6324
|
+
"ResponsiveDialogBody",
|
|
6325
|
+
"ResponsiveDialogClose",
|
|
6326
|
+
"ResponsiveDialogContent",
|
|
6327
|
+
"ResponsiveDialogDescription",
|
|
6328
|
+
"ResponsiveDialogFooter",
|
|
6329
|
+
"ResponsiveDialogHeader",
|
|
6330
|
+
"ResponsiveDialogTitle",
|
|
6331
|
+
"SDK_VERSION",
|
|
6332
|
+
"SchemaForm",
|
|
6333
|
+
"SectionIcon",
|
|
6334
|
+
"SectionTitle",
|
|
6335
|
+
"Select",
|
|
6336
|
+
"SelectContent",
|
|
6337
|
+
"SelectItem",
|
|
6338
|
+
"SelectTrigger",
|
|
6339
|
+
"SelectValue",
|
|
6340
|
+
"Slider",
|
|
6341
|
+
"SwatchPicker",
|
|
6342
|
+
"Switch",
|
|
6343
|
+
"Tabs",
|
|
6344
|
+
"TabsContent",
|
|
6345
|
+
"TabsList",
|
|
6346
|
+
"TabsTrigger",
|
|
6347
|
+
"TemperatureBar",
|
|
6348
|
+
"Toggle",
|
|
6349
|
+
"ToggleGroup",
|
|
6350
|
+
"ToggleGroupItem",
|
|
6351
|
+
"ToneSchema",
|
|
6352
|
+
"Widget",
|
|
6353
|
+
"WidgetAction",
|
|
6354
|
+
"WidgetBackdrop",
|
|
6355
|
+
"WidgetChip",
|
|
6356
|
+
"WidgetChoice",
|
|
6357
|
+
"WidgetContent",
|
|
6358
|
+
"WidgetControls",
|
|
6359
|
+
"WidgetCtx",
|
|
6360
|
+
"WidgetDebugTab",
|
|
6361
|
+
"WidgetDebugView",
|
|
6362
|
+
"WidgetDialog",
|
|
6363
|
+
"WidgetGlyph",
|
|
6364
|
+
"WidgetHead",
|
|
6365
|
+
"WidgetHero",
|
|
6366
|
+
"WidgetIcon",
|
|
6367
|
+
"WidgetLayer",
|
|
6368
|
+
"WidgetManifestSchema",
|
|
6369
|
+
"WidgetSizeCtx",
|
|
6370
|
+
"WidgetSliderFill",
|
|
6371
|
+
"WidgetStatus",
|
|
6372
|
+
"WidgetStepper",
|
|
6373
|
+
"WidgetTitle",
|
|
6374
|
+
"WidgetValue",
|
|
6375
|
+
"buildDebugData",
|
|
6376
|
+
"byDomain",
|
|
6377
|
+
"calculateLightGroup",
|
|
6378
|
+
"calculateSensorGroup",
|
|
6379
|
+
"copyText",
|
|
6380
|
+
"countActiveEntities",
|
|
6381
|
+
"defineConfig",
|
|
6382
|
+
"defineWidget",
|
|
6383
|
+
"deprecations",
|
|
6384
|
+
"field",
|
|
6385
|
+
"formatDeprecation",
|
|
6386
|
+
"formatSchemaError",
|
|
6387
|
+
"getEntityAttribute",
|
|
6388
|
+
"getForecasts",
|
|
6389
|
+
"getStream",
|
|
6390
|
+
"getWebRtcClientConfig",
|
|
6391
|
+
"hassMediaUrl",
|
|
6392
|
+
"imagePreset",
|
|
6393
|
+
"imageSrc",
|
|
6394
|
+
"imageUrl",
|
|
6395
|
+
"injectTokens",
|
|
6396
|
+
"isDark",
|
|
6397
|
+
"isEntityActive",
|
|
6398
|
+
"isPanelControllable",
|
|
6399
|
+
"mediaUrl",
|
|
6400
|
+
"monotoneCubicPath",
|
|
6401
|
+
"parseColor",
|
|
6402
|
+
"presetValue",
|
|
6403
|
+
"provideCameraSource",
|
|
6404
|
+
"sendWebRtcCandidate",
|
|
6405
|
+
"startWebRtcSession",
|
|
6406
|
+
"state",
|
|
6407
|
+
"svgColors",
|
|
6408
|
+
"trackEntityHistory",
|
|
6409
|
+
"untrackEntityHistory",
|
|
6410
|
+
"useArea",
|
|
6411
|
+
"useCalendarEvents",
|
|
6412
|
+
"useCamera",
|
|
6413
|
+
"useCameraSource",
|
|
6414
|
+
"useConfirm",
|
|
6415
|
+
"useConnection",
|
|
6416
|
+
"useCopyText",
|
|
6417
|
+
"useCurrency",
|
|
6418
|
+
"useDaylight",
|
|
6419
|
+
"useEntities",
|
|
6420
|
+
"useEntity",
|
|
6421
|
+
"useEntityHistory",
|
|
6422
|
+
"useEntityStatistics",
|
|
6423
|
+
"useForecast",
|
|
6424
|
+
"useHassConfig",
|
|
6425
|
+
"useIntersectionPause",
|
|
6426
|
+
"useLocale",
|
|
6427
|
+
"useMaterial",
|
|
6428
|
+
"useReducedMotion",
|
|
6429
|
+
"useService",
|
|
6430
|
+
"useStore",
|
|
6431
|
+
"useTemperatureUnit",
|
|
6432
|
+
"useToggle",
|
|
6433
|
+
"useTurnOff",
|
|
6434
|
+
"useTurnOn",
|
|
6435
|
+
"useUnitSystem",
|
|
6436
|
+
"useWidgetContext",
|
|
6437
|
+
"useWidgetDashboard",
|
|
6438
|
+
"useWidgetDialog",
|
|
6439
|
+
"useWidgetDimensions",
|
|
6440
|
+
"useWidgetEntityGroup",
|
|
6441
|
+
"useWidgetGestures",
|
|
6442
|
+
"useWidgetState",
|
|
6443
|
+
"useWidgetViewer",
|
|
6444
|
+
"widgetFields",
|
|
6445
|
+
"z"
|
|
6148
6446
|
]
|
|
6149
6447
|
}
|
package/dist/index.d.ts
CHANGED
|
@@ -1,6 +1,8 @@
|
|
|
1
1
|
export { defineWidget } from "./define-widget";
|
|
2
2
|
export * from "./data";
|
|
3
3
|
export * from "./framework";
|
|
4
|
+
export { type CameraSource, CameraSourceContext, provideCameraSource, useCameraSource, type WebRtcSignal, } from "./media/camera-source";
|
|
5
|
+
export { CameraStream, type CameraStreamProps } from "@glasshome/widget-sdk/media/camera-stream";
|
|
4
6
|
export { monotoneCubicPath } from "./shared/spline";
|
|
5
7
|
export * from "./ui";
|
|
6
8
|
export { formatSchemaError, WidgetManifestSchema } from "./schemas";
|