chromium/third_party/blink/renderer/core/style/position_area.cc

// Copyright 2023 The Chromium Authors
// Use of this source code is governed by a BSD-style license that can be
// found in the LICENSE file.

#ifdef UNSAFE_BUFFERS_BUILD
// TODO(crbug.com/351564777): Remove this and convert code to safer constructs.
#pragma allow_unsafe_buffers
#endif

#include "third_party/blink/renderer/core/style/position_area.h"

#include "base/check_op.h"
#include "third_party/blink/renderer/core/layout/geometry/axis.h"
#include "third_party/blink/renderer/core/style/anchor_specifier_value.h"
#include "third_party/blink/renderer/platform/geometry/calculation_value.h"
#include "third_party/blink/renderer/platform/text/writing_mode_utils.h"
#include "third_party/blink/renderer/platform/wtf/static_constructors.h"

namespace blink {

namespace {

inline PhysicalAxes PhysicalAxisFromRegion(
    PositionAreaRegion region,
    const WritingDirectionMode& container_writing_direction,
    const WritingDirectionMode& self_writing_direction) {}

// Return the physical axis for an position-area span if given by the regions, or
// kPhysicalAxesNone if we need the direction/writing-mode to decide.
inline PhysicalAxes PhysicalAxisFromSpan(
    PositionAreaRegion start,
    PositionAreaRegion end,
    const WritingDirectionMode& container_writing_direction,
    const WritingDirectionMode& self_writing_direction) {}

// Convert a logical region to the corresponding physical region based on the
// span's axis and the direction/writing-mode of the anchored element and its
// containing block.
PositionAreaRegion ToPhysicalRegion(
    PositionAreaRegion region,
    PhysicalAxes axis,
    const WritingDirectionMode& container_writing_direction,
    const WritingDirectionMode& self_writing_direction) {}

}  // namespace

PositionArea PositionArea::ToPhysical(
    const WritingDirectionMode& container_writing_direction,
    const WritingDirectionMode& self_writing_direction) const {}

std::optional<AnchorQuery> PositionArea::UsedTop() const {}

std::optional<AnchorQuery> PositionArea::UsedBottom() const {}

std::optional<AnchorQuery> PositionArea::UsedLeft() const {}

std::optional<AnchorQuery> PositionArea::UsedRight() const {}

std::pair<ItemPosition, ItemPosition> PositionArea::AlignJustifySelfFromPhysical(
    WritingDirectionMode container_writing_direction) const {}

AnchorQuery PositionArea::AnchorTop() {}

AnchorQuery PositionArea::AnchorBottom() {}

AnchorQuery PositionArea::AnchorLeft() {}

AnchorQuery PositionArea::AnchorRight() {}

}  // namespace blink