#pragma once

#include <string>
#include <utility>
#include <yaml-cpp/yaml.h>
#include "Component.h"

namespace OX
{
    class TagComponent : public Component
    {
    public:
        TagComponent() = default;

        explicit TagComponent(std::string tag)
            : name(std::move(tag))
        {
        }

        std::string name;

        /// Serialize into YAML: writes { type: "TagComponent", name: "<your tag>" }
        [[nodiscard]] YAML::Node Serialize() const override;

        /// Deserialize from YAML: reads `.name` from node["name"]
        void Deserialize(const YAML::Node &node) override;
    };
} // namespace OX
