Skip to content

Conversation

@ZhaiSoul
Copy link
Contributor

@ZhaiSoul ZhaiSoul commented Nov 2, 2025

Proposed change

Add zones friend name

Type of change

  • Dependency upgrade
  • Bugfix (non-breaking change which fixes an issue)
  • New feature
  • Breaking change (fix/feature causing existing functionality to break)
  • Code quality improvements to existing code
  • Documentation Update

Additional information

  • This PR fixes or closes issue: fixes #
  • This PR is related to issue:

Checklist

  • The code change is tested and works locally.
  • Local tests pass. Your PR cannot be merged unless tests pass
  • There is no commented out code in this PR.
  • UI changes including text have used i18n keys and have been added to the en locale.
  • The code has been formatted using Ruff (ruff format frigate)

@netlify
Copy link

netlify bot commented Nov 2, 2025

Deploy Preview for frigate-docs ready!

Name Link
🔨 Latest commit 303ebff
🔍 Latest deploy log https://app.netlify.com/projects/frigate-docs/deploys/690a15678386010007695822
😎 Deploy Preview https://deploy-preview-20761--frigate-docs.netlify.app
📱 Preview on mobile
Toggle QR Code...

QR Code

Use your smartphone camera to open QR code link.

To edit notification comments on pull requests, go to your Netlify project configuration.

@hawkeye217
Copy link
Collaborator

Thanks for this PR. A few things:

  1. The reference configuration in the docs needs to be updated.
  2. Editing an existing zone that doesn't have a friendly name should cause the friendly name to default to the existing ID/machine name. See the Triggers code for an example.
  3. It seems like spaces in friendly names are being replaced with underscores. Is there a reason for this? This should behave the same way as camera friendly names.

@ZhaiSoul
Copy link
Contributor Author

ZhaiSoul commented Nov 4, 2025

Thanks for this PR. A few things:

  1. The reference configuration in the docs needs to be updated.
  2. Editing an existing zone that doesn't have a friendly name should cause the friendly name to default to the existing ID/machine name. See the Triggers code for an example.
  3. It seems like spaces in friendly names are being replaced with underscores. Is there a reason for this? This should behave the same way as camera friendly names.

Fixed! Thanks for your review.


// add default points order for already completed polygons
if (!activePolygon.pointsOrder && activePolygon.isFinished) {
if (!activePolygon?.pointsOrder && activePolygon?.isFinished) {
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Were you seeing crashes here? Why was this change necessary?

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Were you seeing crashes here? Why was this change necessary?

yup, crashes may occur after saving, but the cause remains unknown.

Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

We've never had reports of crashes here. It would be good to make sure your changes are not causing an issue.

@hawkeye217
Copy link
Collaborator

hawkeye217 commented Nov 4, 2025

Thanks for the changes.

I was suggesting that you update reference.md, not necessarily the entire zones documentation. I think we'd prefer to keep the language there as-is. You can add the friendly_name field there, but I would also remove the comment about emojis.

ZhaiSoul and others added 2 commits November 4, 2025 22:54
Added optional friendly name for zones in configuration.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants