/* * Copyright (c) 2025, Sam Atkins * * SPDX-License-Identifier: BSD-2-Clause */ #pragma once #include namespace Web::CSS { // https://drafts.css-houdini.org/css-typed-om-1/#cssskew class CSSSkew final : public CSSTransformComponent { WEB_PLATFORM_OBJECT(CSSSkew, CSSTransformComponent); GC_DECLARE_ALLOCATOR(CSSSkew); public: [[nodiscard]] static GC::Ref create(JS::Realm&, GC::Ref ax, GC::Ref ay); static WebIDL::ExceptionOr> construct_impl(JS::Realm&, GC::Ref ax, GC::Ref ay); virtual ~CSSSkew() override; virtual WebIDL::ExceptionOr to_string() const override; virtual WebIDL::ExceptionOr> to_matrix() const override; GC::Ref ax() const { return m_ax; } GC::Ref ay() const { return m_ay; } WebIDL::ExceptionOr set_ax(GC::Ref value); WebIDL::ExceptionOr set_ay(GC::Ref value); virtual void set_is_2d(bool value) override; virtual WebIDL::ExceptionOr> create_style_value(PropertyNameAndID const&) const override; private: explicit CSSSkew(JS::Realm&, GC::Ref ax, GC::Ref ay); virtual void initialize(JS::Realm&) override; virtual void visit_edges(Visitor&) override; GC::Ref m_ax; GC::Ref m_ay; }; }