From 8cdeb6a3bbda40c22835b1f5680768fe713401b4 Mon Sep 17 00:00:00 2001 From: hywax Date: Fri, 26 Jan 2024 12:32:20 +0500 Subject: [PATCH] docs(en): service target --- docs/services/base.md | 24 ++++++++++++++++++++++++ 1 file changed, 24 insertions(+) diff --git a/docs/services/base.md b/docs/services/base.md index 33e41b5..17cd010 100644 --- a/docs/services/base.md +++ b/docs/services/base.md @@ -31,6 +31,30 @@ It is also used to check [status](#status) availability. link: https://home-assistant.home.local/ ``` +## Target + +Browser behavior when the service is clicked. +With this property, you can make the service open in the current or a new window. + +```yaml +target: _blank +``` + +Values: + +| Value | Description | +|-----------|---------------------------------------------------------------------------------------------------------------------------------| +| `_blank` | Usually a new tab, but users can configure browsers to open a new window instead | +| `_self` | The current browsing context | +| `_parent` | The parent browsing context of the current one. If no parent, behaves as `_self` | +| `_top` | The topmost browsing context (the "highest" context that's an ancestor of the current one). If no ancestors, behaves as `_self` | + +Default: `_blank` + +::: warning +This property takes precedence over `behaviour.target` from `config.yml`. You can read more in the [configuration](../reference/configuration.md#target) +::: + ## Icon Service icon. Allows you to quickly find the required item.