#ifndef UI_ACCESSIBILITY_AX_ASSISTANT_STRUCTURE_H_
#define UI_ACCESSIBILITY_AX_ASSISTANT_STRUCTURE_H_
#include <stdint.h>
#include <memory>
#include <optional>
#include <string>
#include <vector>
#include "base/strings/string_split.h"
#include "ui/accessibility/ax_enums.mojom-forward.h"
#include "ui/gfx/geometry/rect.h"
#include "ui/gfx/range/range.h"
namespace ui {
struct AXTreeUpdate;
struct AssistantNode {
AssistantNode();
AssistantNode(const AssistantNode& other);
AssistantNode& operator=(const AssistantNode&) = delete;
~AssistantNode();
std::vector<int32_t> children_indices;
gfx::Rect rect;
gfx::Rect unclipped_rect;
gfx::Rect page_absolute_rect;
std::u16string text;
float text_size;
uint32_t color;
uint32_t bgcolor;
bool bold;
bool italic;
bool underline;
bool line_through;
std::optional<gfx::Range> selection;
std::string class_name;
std::string html_tag;
std::string css_display;
base::StringPairs html_attributes;
std::optional<std::string> role;
};
struct AssistantTree {
AssistantTree();
AssistantTree(const AssistantTree& other);
AssistantTree& operator=(const AssistantTree&) = delete;
~AssistantTree();
std::vector<std::unique_ptr<AssistantNode>> nodes;
};
std::unique_ptr<AssistantTree> CreateAssistantTree(const AXTreeUpdate& update);
std::u16string AXUrlBaseText(std::u16string url);
const char* AXRoleToAndroidClassName(ax::mojom::Role role, bool has_parent);
}
#endif