Merge branch 'main' into release-4.1.0
This commit is contained in:
@@ -11,6 +11,6 @@ jobs:
|
|||||||
runs-on: ubuntu-latest
|
runs-on: ubuntu-latest
|
||||||
steps:
|
steps:
|
||||||
- name: Run release-drafter
|
- name: Run release-drafter
|
||||||
uses: release-drafter/release-drafter@v5.20.1
|
uses: release-drafter/release-drafter@v5.21.0
|
||||||
env:
|
env:
|
||||||
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
|
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
|
||||||
|
|||||||
@@ -9,6 +9,7 @@ import {
|
|||||||
import { localize } from '../../localize/localize.js';
|
import { localize } from '../../localize/localize.js';
|
||||||
import {
|
import {
|
||||||
BrowseMediaQueryParameters,
|
BrowseMediaQueryParameters,
|
||||||
|
BrowseRecordingQueryParameters,
|
||||||
CameraConfig,
|
CameraConfig,
|
||||||
ClipsOrSnapshots,
|
ClipsOrSnapshots,
|
||||||
FrigateBrowseMediaSource,
|
FrigateBrowseMediaSource,
|
||||||
@@ -457,3 +458,23 @@ export const sortYoungestToOldest = (
|
|||||||
}
|
}
|
||||||
return 0;
|
return 0;
|
||||||
};
|
};
|
||||||
|
/**
|
||||||
|
* Generate a recording identifier.
|
||||||
|
* @param hass The HomeAssistant object.
|
||||||
|
* @param params The recording parameters to use in the identifer.
|
||||||
|
* @returns A recording identifier.
|
||||||
|
*/
|
||||||
|
export const generateRecordingIdentifier = (
|
||||||
|
params: BrowseRecordingQueryParameters,
|
||||||
|
): string => {
|
||||||
|
return [
|
||||||
|
'media-source://frigate',
|
||||||
|
params.clientId,
|
||||||
|
'recordings',
|
||||||
|
params.cameraName,
|
||||||
|
`${params.year}-${String(params.month).padStart(2, '0')}-${String(
|
||||||
|
params.day,
|
||||||
|
).padStart(2, '0')}`,
|
||||||
|
String(params.hour).padStart(2, '0'),
|
||||||
|
].join('/');
|
||||||
|
};
|
||||||
|
|||||||
Reference in New Issue
Block a user