mirror of
https://github.com/fergalmoran/ladybird.git
synced 2026-01-03 07:07:23 +00:00
LibWeb: Stub for Credential Management API
Stub out basic Credential Management APIs and import IDL tests. Spec: https://w3c.github.io/webappsec-credential-management/
This commit is contained in:
@@ -0,0 +1,40 @@
|
||||
/*
|
||||
* Copyright (c) 2025, Altomani Gianluca <altomanigianluca@gmail.com>
|
||||
*
|
||||
* SPDX-License-Identifier: BSD-2-Clause
|
||||
*/
|
||||
|
||||
#include <LibWeb/Bindings/Intrinsics.h>
|
||||
#include <LibWeb/CredentialManagement/FederatedCredential.h>
|
||||
|
||||
namespace Web::CredentialManagement {
|
||||
|
||||
GC_DEFINE_ALLOCATOR(FederatedCredential);
|
||||
|
||||
GC::Ref<FederatedCredential> FederatedCredential::create(JS::Realm& realm)
|
||||
{
|
||||
return realm.create<FederatedCredential>(realm);
|
||||
}
|
||||
|
||||
// https://www.w3.org/TR/credential-management-1/#dom-federatedcredential-federatedcredential
|
||||
WebIDL::ExceptionOr<GC::Ref<FederatedCredential>> FederatedCredential::construct_impl(JS::Realm& realm, FederatedCredentialInit const&)
|
||||
{
|
||||
return realm.vm().throw_completion<JS::InternalError>(JS::ErrorType::NotImplemented, "construct"sv);
|
||||
}
|
||||
|
||||
FederatedCredential::~FederatedCredential()
|
||||
{
|
||||
}
|
||||
|
||||
FederatedCredential::FederatedCredential(JS::Realm& realm)
|
||||
: Credential(realm)
|
||||
{
|
||||
}
|
||||
|
||||
void FederatedCredential::initialize(JS::Realm& realm)
|
||||
{
|
||||
Base::initialize(realm);
|
||||
WEB_SET_PROTOTYPE_FOR_INTERFACE(FederatedCredential);
|
||||
}
|
||||
|
||||
}
|
||||
Reference in New Issue
Block a user