# Индексы полей ввода

Иногда бывает так, что появляется необходимость управлять индексами полей ввода. Казалось бы, что для этого неплохо подойтет атрибут tabindex, однако помимо данного атрибута учитываются и другие встроенные компоненты, например ссылки или адресная строка.

Именно из-за таких ситуаций и был разработан данный компонент, который выступает ограничителем.

Атрибут <mark style="color:orange;">`[data-tabindex]`</mark> служит для определения блока в котором работают атрибуты <mark style="color:orange;">`[tabindex]`</mark>

```html
<form method="post" data-tabindex>
    <input type="text" name="name" tabindex="1" placeholder="tabindex=1">

    <input type="text" name="name" tabindex="2" placeholder="tabindex=2">

    <input type="text" name="name" tabindex="5" placeholder="tabindex=5">

    <input type="text" name="name" tabindex="3" placeholder="tabindex=3">

    <input type="text" name="name" tabindex="4" placeholder="tabindex=4">

    <div class="pt-20 text-center">
        <button type="submit" class="btn">Отправить</button>
    </div>
</form>
```

{% embed url="<https://codepen.io/pipui/pen/QWBdgWg>" %}
Пример работы кода выше
{% endembed %}


---

# Agent Instructions: 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:

```
GET https://v1-6-0.pipui.ru/components/tabindex.md?ask=<question>
```

The question should be specific, self-contained, and written in natural language.
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.
