> For AI agents: the complete documentation index is available at /next/llms.txt, the full documentation bundle is available at /next/llms-full.txt.

# relative-inline-end-of

APISummary
## Introduction

The current element is to the left/right of the sibling element corresponding to the specified [`id`](/next/api/css/properties/relative-id.md) in [relative-layout](/next/guide/ui/layout/relative-layout.md).

When [`direction`](/next/api/css/properties/direction.md) is `ltr`, `relative-inline-end-of` is equivalent to [`relative-right-of`](/next/api/css/properties/relative-right-of.md);

When [`direction`](/next/api/css/properties/direction.md) is `rtl/lynx-rtl`, `relative-inline-end-of` is equivalent to [`relative-left-of`](/next/api/css/properties/relative-left-of.md).

## Examples

**This is an example below: css-api**

**Entry:** `src/relative-inline-end-of`
**Bundle:** `dist/relative-inline-end-of.lynx.bundle`

```tsx
import { root, useState } from "@lynx-js/react";
import "./index.scss";

const RelativeInlineEndOf = () => {
  const containerStyle = {
    display: "relative" as const,
    relativeLayoutOnce: true,
    marginBottom: "20px" as const,
    direction: "ltr" as const,
  };

  const container2Style = {
    display: "relative" as const,
    relativeLayoutOnce: true,
    direction: "rtl" as const,
  };

  const titleStyle = {
    fontSize: "50rpx" as const,
    alignSelf: "center" as const,
    fontWeight: "900" as const,
    color: "linear-gradient(120deg ,#0095ff 30% ,#42d392 100%)" as const,
  };

  const view1Style = {
    relativeId: "1",
    relativeCenter: "horizontal" as const,
    display: "linear" as const,
    backgroundColor: "lightgreen",
    alignItems: "center" as const,
    textAlign: "center" as const,
  };

  const view2Style = {
    display: "linear" as const,
    relativeInlineEndOf: "1",
    alignItems: "center" as const,
    relativeAlignBottom: "parent" as const,
    backgroundColor: "lightblue",
  };

  const view3Style = {
    display: "linear" as const,
    relativeInlineEndOf: "1" as const,
    relativeCenter: "vertical" as const,
    alignItems: "center" as const,
    backgroundColor: "pink",
  };
  const textStyle = {
    fontSize: "23rpx" as const,
    fontWeight: "500" as const,
    textAlign: "center" as const,
  };

  return (
    <scroll-view className="root" scroll-orientation="vertical">
      <text style={titleStyle}>direction: ltr</text>
      <view className="container" style={containerStyle}>
        <view style={view1Style}>
          <text style={textStyle}>relative-id: 1</text>
          <text style={textStyle}>relative-center: horizontal</text>
        </view>
        <view style={view2Style}>
          <text style={textStyle}>relative-inline-end-of: 1</text>
          <text style={textStyle}>relative-align-bottom: parent</text>
        </view>
        <view style={view3Style}>
          <text style={textStyle}>relative-inline-end-of: 1</text>
          <text style={textStyle}>relative-center: vertical</text>
        </view>
      </view>
      <text style={titleStyle}>direction: rtl</text>
      <view className="container" style={container2Style}>
        <view style={view1Style}>
          <text style={textStyle}>relative-id: 1</text>
          <text style={textStyle}>relative-center: horizontal</text>
        </view>
        <view style={view2Style}>
          <text style={textStyle}>relative-inline-end-of: 1</text>
          <text style={textStyle}>relative-align-bottom: parent</text>
        </view>
        <view style={view3Style}>
          <text style={textStyle}>relative-inline-end-of: 1</text>
          <text style={textStyle}>relative-center: vertical</text>
        </view>
      </view>
    </scroll-view>
  );
};

root.render(<RelativeInlineEndOf />);

```

v0.11.0



## Syntax

```css
relative-inline-end-of: none;
relative-inline-end-of: 1;
relative-inline-end-of: 2;
```

### Values

The `relative-inline-end-of` property takes the same values as the [`relative-left-of`](/next/api/css/properties/relative-left-of.md).

## Formal definition

| Initial value | `none` |
| Applies to | relative items |
| Inherited | no |
| Animatable |  |


## Formal syntax

```
relative-inline-end-of = none | <number>
```

## Differences from the Web

- There is no such style in web.

## Compatibility

**Compatibility Table**

**Query:** `css.properties.relative-inline-end-of`

[Source](https://github.com/lynx-family/lynx/blob/develop/tools/css_generator/css_defines/167-relative-inline-end-of.json)

| Feature | Android | HarmonyOS | iOS | macOS | Windows | Web |
| --- | --- | --- | --- | --- | --- | --- |
| relative-inline-end-of | Yes (2.0) | Yes (3.4) | Yes (2.0) | Yes (2.0) | Yes (2.0) | No |

**`relative-inline-end-of`**

The current element is to the left/right of the sibling element corresponding to the specified id.

**Specifications:**

