diff --git a/Userland/Libraries/LibWeb/HTML/HTMLButtonElement.cpp b/Userland/Libraries/LibWeb/HTML/HTMLButtonElement.cpp
index c05dc80030..d60904637c 100644
--- a/Userland/Libraries/LibWeb/HTML/HTMLButtonElement.cpp
+++ b/Userland/Libraries/LibWeb/HTML/HTMLButtonElement.cpp
@@ -57,18 +57,18 @@ void HTMLButtonElement::initialize(JS::Realm& realm)
set_prototype(&Bindings::ensure_web_prototype(realm, "HTMLButtonElement"));
}
-DeprecatedString HTMLButtonElement::type() const
+StringView HTMLButtonElement::type() const
{
auto value = deprecated_attribute(HTML::AttributeNames::type);
#define __ENUMERATE_HTML_BUTTON_TYPE_ATTRIBUTE(keyword, _) \
if (value.equals_ignoring_ascii_case(#keyword##sv)) \
- return #keyword;
+ return #keyword##sv;
ENUMERATE_HTML_BUTTON_TYPE_ATTRIBUTES
#undef __ENUMERATE_HTML_BUTTON_TYPE_ATTRIBUTE
// The missing value default and invalid value default are the Submit Button state.
- return "submit";
+ return "submit"sv;
}
HTMLButtonElement::TypeAttributeState HTMLButtonElement::type_state() const
@@ -85,7 +85,7 @@ HTMLButtonElement::TypeAttributeState HTMLButtonElement::type_state() const
return HTMLButtonElement::TypeAttributeState::Submit;
}
-WebIDL::ExceptionOr HTMLButtonElement::set_type(DeprecatedString const& type)
+WebIDL::ExceptionOr HTMLButtonElement::set_type(String const& type)
{
return set_attribute(HTML::AttributeNames::type, type);
}
diff --git a/Userland/Libraries/LibWeb/HTML/HTMLButtonElement.h b/Userland/Libraries/LibWeb/HTML/HTMLButtonElement.h
index dc1182b05d..028a94d723 100644
--- a/Userland/Libraries/LibWeb/HTML/HTMLButtonElement.h
+++ b/Userland/Libraries/LibWeb/HTML/HTMLButtonElement.h
@@ -34,9 +34,9 @@ public:
#undef __ENUMERATE_HTML_BUTTON_TYPE_ATTRIBUTE
};
- DeprecatedString type() const;
+ StringView type() const;
TypeAttributeState type_state() const;
- WebIDL::ExceptionOr set_type(DeprecatedString const&);
+ WebIDL::ExceptionOr set_type(String const&);
// ^EventTarget
// https://html.spec.whatwg.org/multipage/interaction.html#the-tabindex-attribute:the-button-element
diff --git a/Userland/Libraries/LibWeb/HTML/HTMLButtonElement.idl b/Userland/Libraries/LibWeb/HTML/HTMLButtonElement.idl
index 952deaa442..6e58725ed6 100644
--- a/Userland/Libraries/LibWeb/HTML/HTMLButtonElement.idl
+++ b/Userland/Libraries/LibWeb/HTML/HTMLButtonElement.idl
@@ -1,7 +1,7 @@
#import
// https://html.spec.whatwg.org/multipage/semantics.html#htmlbuttonelement
-[Exposed=Window, UseDeprecatedAKString]
+[Exposed=Window]
interface HTMLButtonElement : HTMLElement {
[HTMLConstructor] constructor();