> For the complete documentation index, see [llms.txt](https://docs.nexthink.com/platform/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://docs.nexthink.com/platform/ja/user-guide/adopt/guide-creation-and-management-from-nexthink-applications/configuring-adoption-settings/use-case-element-selectors-for-salesforce-lightning.md).

# ユースケース: Salesforce Lightning用のエレメントセレクター

**Salesforce Lightning**の**Adoption設定**を構成する際には、以下の目的でこのページの**要素セレクター**を使用してください。

* 動的識別子を避けることで、要素選択の安定性と信頼性を最大化します。
* Salesforce Lightningからのウェブページ変更へのガイドの耐性を強化します。

### Salesforce Lightning用の要素セレクター

Nexthinkで構成されたSalesforce Webアプリケーションのために、Nexthinkの**Adoption設定**タブ > [設定サブタブ](/platform/ja/user-guide/adopt/guide-creation-and-management-from-nexthink-applications/configuring-adoption-settings.md#configuring-adoption-settings-for-the-selected-application) から：

* **無視する要素ID**: `^salesforce-lightning-tooltip-bubble_[a-f0-9-]+$, ^tt-for-\d+:\d+;a(-tt-adv)?$, ^calendarToggle-, ^\w{2}$, ^edit-, ^[a-f0-9]{8}-[a-f0-9]{4}-[a-f0-9]{4}-[a-f0-9]{4}-[a-f0-9]{12}$, ^[A-Z0-9]{18}$`
* **要素ID置換**: このケースでは、IDまたはクラス名セレクターからシステムに動的コンポーネントおよび数字を除去し、関心のある静的セグメントのみを保持させます。
  * *ID* フィールドに `^(([a-zA-Z0-9]+[-_])+)(\d+)(:(\d+))?$` と入力してください。 このコードは要素ID内の任意の番号を表します。
  * *Replacer* フィールドには `[id^="$1"][id$="$2"]` と入力します。 このコードは、ID内の番号の前後にある要素IDのセグメントを表しています。
  * 以下の[要素ID置換例](#element-id-replacement-example)を参照してください。
* **無視する要素クラス名**: `^outputLookupLink-, ^sutbmqjadod$, ^ng-charthover$, ^idc0_\d+$, ^outputLookupLink-[A-Za-z0-9]+-703:0$, ^qe-subject-id-[A-Za-z0-9]+$, ^splashPage-r\d+$, ^slds-r\d+$, ^private-ssr-placeholder-class$` このコードはクラス名内の数字を表します。
* **含まれる要素のカスタム属性名**: `alt, aria-description, aria-label, data-component-id, data-id, data-key, data-name, data-label, icon-name, placeholder, scope, title, variant`
* **ドロップダウンリストセレクター**: 適切な機能の動作を保証するため、このフィールドを空のままにしてください。

<details>

<summary>要素ID置換の例</summary>

**要素ID置換**フィールドを次のように定義した後:

* *ID*: `^(([a-zA-Z0-9]+[-_])+)(\d+)(:(\d+))?$`
* *置換*: `[id^="$1"][id$="$2"]`

次の要素IDの例の場合:

`<span id="entassetrequesttableall_23_EntAssetRequestTableCreate_label">abc</span>`

1. このCSS要素セレクタには動的な要素が含まれています—この場合、番号 `23`:

```
span#entassetrequesttableall_23_EntAssetRequestTableCreate_label.button-label:nth-child(3)
```

2. システムは静的な要素のみを取り入れてCSSセレクタを修正します。その結果:

```
span.button-label[id^="entassetrequesttableall_"][id$="_EntAssetRequestTableCreate_label"]:nth-child(3)
```

* `[id^="entassetrequesttableall_"]` は、要素IDが `entassetrequesttableall_` で始まることを意味します。
* `[id$="_EntAssetRequestTableCreate_label"]` は、要素IDが `_EntAssetRequestTableCreate_label` で終わることを意味します。

</details>

{% hint style="warning" %}
残りの**導入設定**、特に**ガイドのデフォルト**についてはNexthinkのデフォルト構成を使用してください。

あなたの設定は下の画像のようになります。
{% endhint %}

<figure><img src="/files/n5iPNYh78PzfTXFX16UB" alt=""><figcaption></figcaption></figure>


---

# Agent Instructions
This documentation is published with GitBook. GitBook is the documentation platform designed so that both humans and AI agents can read, navigate, and reason over technical content effectively. Learn more at gitbook.com.

## Querying This Documentation
If you need additional information that is not directly available in this page, you can query the documentation dynamically by asking a question.

Perform an HTTP GET request on the current page URL with the `ask` query parameter, and the optional `goal` query parameter:

```
GET https://docs.nexthink.com/platform/ja/user-guide/adopt/guide-creation-and-management-from-nexthink-applications/configuring-adoption-settings/use-case-element-selectors-for-salesforce-lightning.md?ask=<question>&goal=<endgoal>
```

`ask` is the immediate question: it should be specific, self-contained, and written in natural language.
`goal` is optional and describes the broader end goal you are ultimately trying to accomplish on behalf of the user. GitBook uses it to tailor the answer towards what is most useful for that goal.

The response will contain a direct answer to the question and relevant excerpts and sources from the documentation.

Use this mechanism when the answer is not explicitly present in the current page, you need clarification or additional context, or you want to retrieve related documentation sections.
