#pragma once

#include "UIConstants.hpp"
#include <SDL.h>
#include <SDL_ttf.h>
#include <string>
#include <algorithm>

namespace GModTeach {
namespace UI {

class ProgressBar {
public:
    ProgressBar(SDL_Rect bounds);

    void SetProgress(float value);
    [[nodiscard]] float GetProgress() const { return m_progress; }

    void SetStatusText(const std::string& text) { m_statusText = text; }
    [[nodiscard]] const std::string& GetStatusText() const { return m_statusText; }

    void Draw(SDL_Renderer* renderer, TTF_Font* font = nullptr) const;

private:
    SDL_Rect m_bounds;
    float m_progress = 0.0f;
    std::string m_statusText;
};

} 
} 
